diff options
author | Jeong-Seok Yang <jseok.yang@samsung.com> | 2010-10-26 22:19:27 -0700 |
---|---|---|
committer | Wu-cheng Li <wuchengli@google.com> | 2010-10-29 01:07:17 +0900 |
commit | a75b35c7a434a8e15015ed29b7168dac8d85dfb8 (patch) | |
tree | 33fe10233d164e94f007d6a4b87bbf469494879e /libcamera | |
parent | 0f5a5274024492536dab8dafa85ed1334aeff304 (diff) | |
download | device_samsung_crespo-a75b35c7a434a8e15015ed29b7168dac8d85dfb8.zip device_samsung_crespo-a75b35c7a434a8e15015ed29b7168dac8d85dfb8.tar.gz device_samsung_crespo-a75b35c7a434a8e15015ed29b7168dac8d85dfb8.tar.bz2 |
libcamera: for setting fixed frame rate on only camcording mode
Camera sensor change its frame rate by brightness.
It makes video that have too low fps in the dark.
So it use fixed frame rate on camcording mode.
Change-Id: I6ca4cf13e733629c75d244e79443b36b5dba59a5
Signed-off-by: Jeong-Seok Yang <jseok.yang@samsung.com>
pid:3640
Diffstat (limited to 'libcamera')
-rw-r--r-- | libcamera/SecCamera.cpp | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/libcamera/SecCamera.cpp b/libcamera/SecCamera.cpp index 1519be8..4a6959b 100644 --- a/libcamera/SecCamera.cpp +++ b/libcamera/SecCamera.cpp @@ -1065,9 +1065,14 @@ int SecCamera::startRecord(void) LOGE("%s: m_recording_width = %d, m_recording_height = %d\n", __func__, m_recording_width, m_recording_height); ret = fimc_v4l2_s_fmt(m_cam_fd2, m_recording_width, m_recording_height, m_record_v4lformat, 0); - CHECK(ret); + if (m_camera_id == CAMERA_ID_BACK) { + ret = fimc_v4l2_s_ctrl(m_cam_fd, V4L2_CID_CAMERA_FRAME_RATE, + m_params->capture.timeperframe.denominator); + CHECK(ret); + } + init_yuv_buffers(m_buffers_c2, m_recording_width, m_recording_height, m_record_v4lformat); #else /* SWP1_CAMERA_ADD_ADVANCED_FUNCTION */ ret = fimc_v4l2_s_fmt(m_cam_fd2, m_preview_width, m_preview_height, m_record_v4lformat, 0); @@ -1115,6 +1120,12 @@ int SecCamera::stopRecord(void) int ret = fimc_v4l2_streamoff(m_cam_fd2); + if (m_camera_id == CAMERA_ID_BACK) { + ret = fimc_v4l2_s_ctrl(m_cam_fd, V4L2_CID_CAMERA_FRAME_RATE, + FRAME_RATE_AUTO); + CHECK(ret); + } + m_flag_record_start = 0; CHECK(ret); |