Merge "mm-video-v4l2: venc: add dynamic flip support"
diff --git a/mm-video-v4l2/vidc/venc/inc/video_encoder_device_v4l2.h b/mm-video-v4l2/vidc/venc/inc/video_encoder_device_v4l2.h
index 0bc575b..7420dbb 100644
--- a/mm-video-v4l2/vidc/venc/inc/video_encoder_device_v4l2.h
+++ b/mm-video-v4l2/vidc/venc/inc/video_encoder_device_v4l2.h
@@ -525,6 +525,7 @@
QOMX_VIDEO_INTRAPERIODTYPE intraperiod;
OMX_CONFIG_INTRAREFRESHVOPTYPE intravoprefresh;
OMX_CONFIG_ROTATIONTYPE rotation;
+ OMX_CONFIG_MIRRORTYPE mirror;
OMX_VIDEO_VP8REFERENCEFRAMETYPE vp8refframe;
OMX_QCOM_VIDEO_CONFIG_LTRMARK_TYPE markltr;
OMX_QCOM_VIDEO_CONFIG_LTRUSE_TYPE useltr;
diff --git a/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2.cpp b/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2.cpp
index de9b696..90913e3 100644
--- a/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2.cpp
+++ b/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2.cpp
@@ -616,6 +616,11 @@
if (!venc_config_bitrate(&iter->config_data.bitrate))
goto bailout;
break;
+ case OMX_IndexConfigCommonMirror:
+ DEBUG_PRINT_LOW("handle_dynamic_config: OMX_IndexConfigCommonMirror");
+ if (!venc_set_mirror(iter->config_data.mirror.eMirror))
+ goto bailout;
+ break;
default:
DEBUG_PRINT_ERROR("Unsupported dynamic config type %d with timestamp %lld us", iter->type, iter->timestamp);
goto bailout;
diff --git a/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2_params.cpp b/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2_params.cpp
index 6ffaf4f..0ddc8ce 100644
--- a/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2_params.cpp
+++ b/mm-video-v4l2/vidc/venc/src/video_encoder_device_v4l2_params.cpp
@@ -480,6 +480,9 @@
case OMX_IndexConfigVideoVp8ReferenceFrame:
memcpy(&newConfig.config_data.vp8refframe, config, sizeof(OMX_VIDEO_VP8REFERENCEFRAMETYPE));
break;
+ case OMX_IndexConfigCommonMirror:
+ memcpy(&newConfig.config_data.mirror, config, sizeof(OMX_CONFIG_MIRRORTYPE));
+ break;
default:
DEBUG_PRINT_INFO("Unsupported dynamic config.");
return false;