Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5578077a authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "DO NOT MERGE - Merge pie-platform-release (PPRL.190705.004) into master"

parents 40c6dc5e 626cac9f
Loading
Loading
Loading
Loading
+34 −1
Original line number Diff line number Diff line
@@ -812,7 +812,10 @@ public class Camera {
     *
     * @throws RuntimeException if starting preview fails; usually this would be
     *    because of a hardware or other low-level error, or because release()
     *    has been called on this Camera instance.
     *    has been called on this Camera instance. The QCIF (176x144) exception
     *    mentioned in {@link Parameters#setPreviewSize setPreviewSize} and
     *    {@link Parameters#setPictureSize setPictureSize} can also cause this
     *    exception be thrown.
     */
    public native final void startPreview();

@@ -2863,6 +2866,16 @@ public class Camera {
         * orientation should also be considered while setting picture size and
         * thumbnail size.
         *
         * Exception on 176x144 (QCIF) resolution:
         * Camera devices usually have a fixed capability for downscaling from
         * larger resolution to smaller, and the QCIF resolution sometimes
         * is not fully supported due to this limitation on devices with
         * high-resolution image sensors. Therefore, trying to configure a QCIF
         * preview size with any picture or video size larger than 1920x1080
         * (either width or height) might not be supported, and
         * {@link #setParameters(Camera.Parameters)} might throw a
         * RuntimeException if it is not.
         *
         * @param width  the width of the pictures, in pixels
         * @param height the height of the pictures, in pixels
         * @see #setDisplayOrientation(int)
@@ -2908,6 +2921,16 @@ public class Camera {
         * preview can be different from the resolution of the recorded video
         * during video recording.</p>
         *
         * <p>Exception on 176x144 (QCIF) resolution:
         * Camera devices usually have a fixed capability for downscaling from
         * larger resolution to smaller, and the QCIF resolution sometimes
         * is not fully supported due to this limitation on devices with
         * high-resolution image sensors. Therefore, trying to configure a QCIF
         * video resolution with any preview or picture size larger than
         * 1920x1080  (either width or height) might not be supported, and
         * {@link #setParameters(Camera.Parameters)} will throw a
         * RuntimeException if it is not.</p>
         *
         * @return a list of Size object if camera has separate preview and
         *         video output; otherwise, null is returned.
         * @see #getPreferredPreviewSizeForVideo()
@@ -3202,6 +3225,16 @@ public class Camera {
         * <p>Applications need to consider the display orientation. See {@link
         * #setPreviewSize(int,int)} for reference.</p>
         *
         * <p>Exception on 176x144 (QCIF) resolution:
         * Camera devices usually have a fixed capability for downscaling from
         * larger resolution to smaller, and the QCIF resolution sometimes
         * is not fully supported due to this limitation on devices with
         * high-resolution image sensors. Therefore, trying to configure a QCIF
         * picture size with any preview or video size larger than 1920x1080
         * (either width or height) might not be supported, and
         * {@link #setParameters(Camera.Parameters)} might throw a
         * RuntimeException if it is not.</p>
         *
         * @param width  the width for pictures, in pixels
         * @param height the height for pictures, in pixels
         * @see #setPreviewSize(int,int)
+13 −1
Original line number Diff line number Diff line
@@ -2136,6 +2136,12 @@ public final class CameraCharacteristics extends CameraMetadata<CameraCharacteri
     * </table>
     * <p>Refer to {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} for additional
     * mandatory stream configurations on a per-capability basis.</p>
     * <p>Exception on 176x144 (QCIF) resolution: camera devices usually have a fixed capability for
     * downscaling from larger resolution to smaller, and the QCIF resolution sometimes is not
     * fully supported due to this limitation on devices with high-resolution image sensors.
     * Therefore, trying to configure a QCIF resolution stream together with any other
     * stream larger than 1920x1080 resolution (either width or height) might not be supported,
     * and capture session creation will fail if it is not.</p>
     * <p>This key is available on all devices.</p>
     *
     * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
@@ -2331,6 +2337,12 @@ public final class CameraCharacteristics extends CameraMetadata<CameraCharacteri
     * ratio 4:3, and the JPEG encoder alignment requirement is 16, the maximum JPEG size will be
     * 3264x2448.</li>
     * </ul>
     * <p>Exception on 176x144 (QCIF) resolution: camera devices usually have a fixed capability on
     * downscaling from larger resolution to smaller ones, and the QCIF resolution can sometimes
     * not be fully supported due to this limitation on devices with high-resolution image
     * sensors. Therefore, trying to configure a QCIF resolution stream together with any other
     * stream larger than 1920x1080 resolution (either width or height) might not be supported,
     * and capture session creation will fail if it is not.</p>
     * <p>This key is available on all devices.</p>
     *
     * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
@@ -3188,7 +3200,7 @@ public final class CameraCharacteristics extends CameraMetadata<CameraCharacteri
     * <li><code>LEVEL_3</code> devices additionally support YUV reprocessing and RAW image capture, along
     *   with additional output stream configurations.</li>
     * <li><code>EXTERNAL</code> devices are similar to <code>LIMITED</code> devices with exceptions like some sensor or
     *   lens information not reorted or less stable framerates.</li>
     *   lens information not reported or less stable framerates.</li>
     * </ul>
     * <p>See the individual level enums for full descriptions of the supported capabilities.  The
     * {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} entry describes the device's capabilities at a
+8 −0
Original line number Diff line number Diff line
@@ -433,6 +433,14 @@ public abstract class CameraDevice implements AutoCloseable {
     * target combinations with sizes outside of these guarantees, but this can only be tested for
     * by attempting to create a session with such targets.</p>
     *
     * <p>Exception on 176x144 (QCIF) resolution:
     * Camera devices usually have a fixed capability for downscaling from larger resolution to
     * smaller, and the QCIF resolution sometimes is not fully supported due to this
     * limitation on devices with high-resolution image sensors. Therefore, trying to configure a
     * QCIF resolution stream together with any other stream larger than 1920x1080 resolution
     * (either width or height) might not be supported, and capture session creation will fail if it
     * is not.</p>
     *
     * @param outputs The new set of Surfaces that should be made available as
     *                targets for captured image data.
     * @param callback The callback to notify about the status of the new capture session.
+24 −2
Original line number Diff line number Diff line
@@ -75,7 +75,8 @@ public class SurfaceControl implements Parcelable {
            boolean allLayers, boolean useIdentityTransform, int rotation);
    private static native GraphicBuffer nativeScreenshotToBuffer(IBinder displayToken,
            Rect sourceCrop, int width, int height, int minLayer, int maxLayer,
            boolean allLayers, boolean useIdentityTransform, int rotation);
            boolean allLayers, boolean useIdentityTransform, int rotation,
            boolean captureSecureLayers);
    private static native void nativeScreenshot(IBinder displayToken, Surface consumer,
            Rect sourceCrop, int width, int height, int minLayer, int maxLayer,
            boolean allLayers, boolean useIdentityTransform);
@@ -1299,7 +1300,28 @@ public class SurfaceControl implements Parcelable {
        IBinder displayToken = SurfaceControl.getBuiltInDisplay(
                SurfaceControl.BUILT_IN_DISPLAY_ID_MAIN);
        return nativeScreenshotToBuffer(displayToken, sourceCrop, width, height,
                minLayer, maxLayer, false, useIdentityTransform, rotation);
                minLayer, maxLayer, false, useIdentityTransform, rotation,
                false /* captureSecureLayers */);
    }

    /**
     * Like screenshotToBuffer, but if the caller is AID_SYSTEM, allows
     * for the capture of secure layers. This is used for the screen rotation
     * animation where the system server takes screenshots but does
     * not persist them or allow them to leave the server. However in other
     * cases in the system server, we mostly want to omit secure layers
     * like when we take a screenshot on behalf of the assistant.
     *
     * @hide
     */
    public static GraphicBuffer screenshotToBufferWithSecureLayersUnsafe(Rect sourceCrop,
            int width, int height, int minLayer, int maxLayer, boolean useIdentityTransform,
            int rotation) {
        IBinder displayToken = SurfaceControl.getBuiltInDisplay(
                SurfaceControl.BUILT_IN_DISPLAY_ID_MAIN);
        return nativeScreenshotToBuffer(displayToken, sourceCrop, width, height,
                minLayer, maxLayer, false, useIdentityTransform, rotation,
                true /* captureSecureLayers */);
    }

    /**
+5 −3
Original line number Diff line number Diff line
@@ -102,9 +102,11 @@ public class WebViewClient {

    /**
     * Notify the host application that a page has finished loading. This method
     * is called only for main frame. When onPageFinished() is called, the
     * rendering picture may not be updated yet. To get the notification for the
     * new Picture, use {@link WebView.PictureListener#onNewPicture}.
     * is called only for main frame. Receiving an {@code onPageFinished()} callback does not
     * guarantee that the next frame drawn by WebView will reflect the state of the DOM at this
     * point. In order to be notified that the current DOM state is ready to be rendered, request a
     * visual state callback with {@link WebView#postVisualStateCallback} and wait for the supplied
     * callback to be triggered.
     *
     * @param view The WebView that is initiating the callback.
     * @param url The url of the page.
Loading