From: Jeongmo Yang Date: Wed, 19 Oct 2016 08:23:18 +0000 (+0900) Subject: Keep preview display when start or finish video recording X-Git-Tag: accepted/tizen/common/20161019.145746^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e8a2416a5f8e5ab89dd034599532edaa306e48fc;p=platform%2Fcore%2Fmultimedia%2Flibmm-camcorder.git Keep preview display when start or finish video recording [Version] 0.10.84 [Profile] Common [Issue Type] Issue resolve [Dependency module] N/A [Dependency commit] N/A [Test] [M(T) - Boot=(OK), sdb=(OK), Home=(OK), Touch=(OK), Version=tizen-mobile_20161018.2] Change-Id: Ib16f61bb26963bee094be279048febe19506e7d8 Signed-off-by: Jeongmo Yang --- diff --git a/packaging/libmm-camcorder.spec b/packaging/libmm-camcorder.spec index 719e619..b884adc 100644 --- a/packaging/libmm-camcorder.spec +++ b/packaging/libmm-camcorder.spec @@ -1,6 +1,6 @@ Name: libmm-camcorder Summary: Camera and recorder library -Version: 0.10.83 +Version: 0.10.84 Release: 0 Group: Multimedia/Libraries License: Apache-2.0 diff --git a/src/mm_camcorder_videorec.c b/src/mm_camcorder_videorec.c index cb18b85..5acb1ef 100644 --- a/src/mm_camcorder_videorec.c +++ b/src/mm_camcorder_videorec.c @@ -642,6 +642,7 @@ int _mmcamcorder_video_command(MMHandleType handle, int command) MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", TRUE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", TRUE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", TRUE); ret = _mmcamcorder_gst_set_state(handle, pipeline, GST_STATE_READY); @@ -654,6 +655,7 @@ int _mmcamcorder_video_command(MMHandleType handle, int command) MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", FALSE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", FALSE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", FALSE); if (ret != MM_ERROR_NONE) goto _ERR_CAMCORDER_VIDEO_COMMAND; @@ -930,6 +932,7 @@ int _mmcamcorder_video_command(MMHandleType handle, int command) /* restart preview */ MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", TRUE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", TRUE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", TRUE); ret = _mmcamcorder_gst_set_state(handle, pipeline, GST_STATE_READY); @@ -941,6 +944,7 @@ int _mmcamcorder_video_command(MMHandleType handle, int command) MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", FALSE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", FALSE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", FALSE); if (ret != MM_ERROR_NONE) goto _ERR_CAMCORDER_VIDEO_COMMAND; @@ -1198,6 +1202,7 @@ int _mmcamcorder_video_handle_eos(MMHandleType handle) /* block queue */ MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", TRUE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", TRUE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", TRUE); _mmcam_dbg_log("Set state of pipeline as READY"); ret = _mmcamcorder_gst_set_state(handle, sc->element[_MMCAMCORDER_MAIN_PIPE].gst, GST_STATE_READY); @@ -1211,6 +1216,8 @@ int _mmcamcorder_video_handle_eos(MMHandleType handle) /* unblock queue */ MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_QUE].gst, "empty-buffers", FALSE); MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSRC_QUE].gst, "empty-buffers", FALSE); + MMCAMCORDER_G_OBJECT_SET(sc->element[_MMCAMCORDER_VIDEOSINK_SINK].gst, "keep-camera-preview", FALSE); + if (ret != MM_ERROR_NONE) { msg.id = MM_MESSAGE_CAMCORDER_ERROR; msg.param.code = ret;