diff options
author | hoony.yu <hoony.yu@samsung.com> | 2010-09-19 17:44:20 -0700 |
---|---|---|
committer | Simon Wilson <simonwilson@google.com> | 2010-09-20 13:57:13 -0700 |
commit | 96323f74bc43a2a85043c030f5f19fff39ee3fc3 (patch) | |
tree | 53bd1b069408fe319da07a597fe441e9162c6c6f /libcamera | |
parent | 41b855f0cea2e4e7d7afd16aa69fdcb6983a950c (diff) | |
download | device_samsung_crespo-96323f74bc43a2a85043c030f5f19fff39ee3fc3.zip device_samsung_crespo-96323f74bc43a2a85043c030f5f19fff39ee3fc3.tar.gz device_samsung_crespo-96323f74bc43a2a85043c030f5f19fff39ee3fc3.tar.bz2 |
S5PC11X: OVERLAY: Patch for picture cature
3008600 After picture capture the preview screen goes black on Crespo
Change-Id: I86c1c4aa5c4e51b536186d4567e9ed2d571f280b
Signed-off-by: hoony.yu <hoony.yu@samsung.com>
Diffstat (limited to 'libcamera')
-rwxr-xr-x | libcamera/SecCameraHWInterface.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/libcamera/SecCameraHWInterface.cpp b/libcamera/SecCameraHWInterface.cpp index e37a247..4615de0 100755 --- a/libcamera/SecCameraHWInterface.cpp +++ b/libcamera/SecCameraHWInterface.cpp @@ -305,6 +305,14 @@ CameraHardwareSec::~CameraHardwareSec() if(mRecordHeap != NULL) mRecordHeap.clear(); +#if defined(BOARD_USES_OVERLAY) + if(mUseOverlay) { + mOverlay->destroy(); + mUseOverlay = false; + mOverlay = NULL; + } +#endif + mSecCamera = NULL; singleton.clear(); @@ -405,7 +413,10 @@ int CameraHardwareSec::previewThread() overlay_buffer_t overlay_buffer; ret = mOverlay->dequeueBuffer(&overlay_buffer); - if (ret == -1) { + + if (ret == ALL_BUFFERS_FLUSHED) { + goto OverlayEnd; + } else if (ret == -1) { LOGE("ERR(%s):overlay dequeueBuffer fail", __func__); goto OverlayEnd; } @@ -674,14 +685,6 @@ void CameraHardwareSec::stopPreview() mPreviewRunning = false; -#if defined(BOARD_USES_OVERLAY) - if(mUseOverlay) { - mOverlay->destroy(); - mUseOverlay = false; - mOverlay = NULL; - } -#endif - } bool CameraHardwareSec::previewEnabled() { |