QCamera2: HAL3: Support both EIS and OIS
EIS should not automatically be disabled just because the device also
supports OIS.
CRs-fixed: 2019531
Bug: 36191178
Test: Build and run locally. Confirm the stabilization option is
available in GCA.
Authored-by: Jason Lee <leejason@codeaurora.org>
Change-Id: I9420ccb7f9c75fc5ba5014ecdbcfba2f27b2c39c
diff --git a/msm8998/QCamera2/HAL3/QCamera3HWI.cpp b/msm8998/QCamera2/HAL3/QCamera3HWI.cpp
index aa8fc9d..d8880a4 100644
--- a/msm8998/QCamera2/HAL3/QCamera3HWI.cpp
+++ b/msm8998/QCamera2/HAL3/QCamera3HWI.cpp
@@ -1632,7 +1632,6 @@
cam_padding_info_t padding_info = gCamCapability[mCameraId]->padding_info;
/*EIS configuration*/
- bool oisSupported = false;
uint8_t eis_prop_set;
uint32_t maxEisWidth = 0;
uint32_t maxEisHeight = 0;
@@ -1657,14 +1656,6 @@
break;
}
}
- count = CAM_OPT_STAB_MAX;
- count = MIN(gCamCapability[mCameraId]->optical_stab_modes_count, count);
- for (size_t i = 0; i < count; i++) {
- if (gCamCapability[mCameraId]->optical_stab_modes[i] == CAM_OPT_STAB_ON) {
- oisSupported = true;
- break;
- }
- }
if (m_bEisSupported) {
maxEisWidth = MAX_EIS_WIDTH;
@@ -1677,11 +1668,11 @@
property_get("persist.camera.eis.enable", eis_prop, "1");
eis_prop_set = (uint8_t)atoi(eis_prop);
- m_bEisEnable = eis_prop_set && (!oisSupported && m_bEisSupported) &&
+ m_bEisEnable = eis_prop_set && m_bEisSupported &&
(mOpMode != CAMERA3_STREAM_CONFIGURATION_CONSTRAINED_HIGH_SPEED_MODE);
- LOGD("m_bEisEnable: %d, eis_prop_set: %d, m_bEisSupported: %d, oisSupported:%d ",
- m_bEisEnable, eis_prop_set, m_bEisSupported, oisSupported);
+ LOGD("m_bEisEnable: %d, eis_prop_set: %d, m_bEisSupported: %d",
+ m_bEisEnable, eis_prop_set, m_bEisSupported);
/* stream configurations */
for (size_t i = 0; i < streamList->num_streams; i++) {