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

Commit ffdfcd7f authored by Igor Murashkin's avatar Igor Murashkin Committed by Android (Google) Code Review
Browse files

Merge "camera2: legacy: Don't set the @hide frame number metadata" into lmp-dev

parents 36761644 56678d87
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -601,7 +601,6 @@ public class LegacyMetadataMapper {
                    CaptureResult.JPEG_QUALITY                                     ,
                    CaptureResult.JPEG_THUMBNAIL_QUALITY                           ,
                    CaptureResult.LENS_FOCAL_LENGTH                                ,
                    CaptureResult.REQUEST_FRAME_COUNT                              ,
                    CaptureResult.REQUEST_PIPELINE_DEPTH                           ,
                    CaptureResult.SCALER_CROP_REGION                               ,
                    CaptureResult.SENSOR_TIMESTAMP                                 ,
+2 −7
Original line number Diff line number Diff line
@@ -57,12 +57,11 @@ public class LegacyResultMapper {
     *
     * @param legacyRequest a non-{@code null} legacy request containing the latest parameters
     * @param timestamp the timestamp to use for this result in nanoseconds.
     * @param frameCounter a monotonically increasing frame counter for the result
     *
     * @return {@link CameraMetadataNative} object containing result metadata.
     */
    public CameraMetadataNative cachedConvertResultMetadata(
            LegacyRequest legacyRequest, long timestamp, long frameCounter) {
            LegacyRequest legacyRequest, long timestamp) {
        CameraMetadataNative result;
        boolean cached;

@@ -86,17 +85,13 @@ public class LegacyResultMapper {
         * Unconditionally set fields that change in every single frame
         */
        {
            // request.frameCounter
            result.set(REQUEST_FRAME_COUNT, (int)frameCounter);
            // TODO: fix CaptureResult#getFrameNumber not to need this key

            // sensor.timestamp
            result.set(SENSOR_TIMESTAMP, timestamp);
        }

        if (VERBOSE) {
            Log.v(TAG, "cachedConvertResultMetadata - cached? " + cached +
                    " frameCounter = " + frameCounter + " timestamp = " + timestamp);
                    " timestamp = " + timestamp);

            Log.v(TAG, "----- beginning of result dump ------");
            result.dumpToLog();
+1 −1
Original line number Diff line number Diff line
@@ -674,7 +674,7 @@ public class RequestThreadManager {
                        }

                        CameraMetadataNative result = mMapper.cachedConvertResultMetadata(
                                mLastRequest, timestampMutable.value, holder.getFrameNumber());
                                mLastRequest, timestampMutable.value);
                        // Update AF state
                        mFocusStateMapper.mapResultTriggers(result);