mirror of
https://github.com/openharmony/multimedia_camera_standard.git
synced 2026-06-30 20:48:03 -04:00
Repairing the problem of camera zoom black screen
Signed-off-by: mali <mali81@huawei.com>
This commit is contained in:
@@ -191,11 +191,12 @@ void HCameraDevice::ReportFlashEvent(const std::shared_ptr<OHOS::Camera::CameraM
|
||||
int ret = OHOS::Camera::FindCameraMetadataItem(settings->get(), OHOS_CONTROL_FLASH_MODE, &item);
|
||||
if (ret == CAM_META_SUCCESS) {
|
||||
flashMode = static_cast<camera_flash_mode_enum_t>(item.data.u8[0]);
|
||||
POWERMGR_SYSEVENT_FLASH_ON();
|
||||
} else {
|
||||
MEDIA_ERR_LOG("ReportFlashEvent::GetFlashMode Failed with return code %{public}d", ret);
|
||||
flashMode = OHOS_CAMERA_FLASH_MODE_CLOSE;
|
||||
}
|
||||
|
||||
if (flashMode == OHOS_CAMERA_FLASH_MODE_CLOSE) {
|
||||
POWERMGR_SYSEVENT_FLASH_OFF();
|
||||
} else {
|
||||
POWERMGR_SYSEVENT_FLASH_ON();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user