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

Commit 75b0f028 authored by Shuzhen Wang's avatar Shuzhen Wang
Browse files

Camera: move preCorrectionActiveArraySize override to cameraserver

This is to handle the case where HAL isn't using the hidl shim.

Test: dumpsys on Pixel 2
Bug: 145300768
Change-Id: I74874a025904887cc27ec00518f4261dd24e291a
parent e67a810c
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
@@ -194,16 +194,6 @@ void CameraModule::deriveCameraCharacteristicsKeys(
        }
    }

    // Always add a default for the pre-correction active array if the vendor chooses to omit this
    camera_metadata_entry entry = chars.find(ANDROID_SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE);
    if (entry.count == 0) {
        Vector<int32_t> preCorrectionArray;
        entry = chars.find(ANDROID_SENSOR_INFO_ACTIVE_ARRAY_SIZE);
        preCorrectionArray.appendArray(entry.data.i32, entry.count);
        chars.update(ANDROID_SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE, preCorrectionArray);
        derivedCharKeys.push(ANDROID_SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE);
    }

    // Add those newly added keys to AVAILABLE_CHARACTERISTICS_KEYS
    // This has to be done at this end of this function.
    if (derivedCharKeys.size() > 0) {