summaryrefslogtreecommitdiffstats
path: root/services/camera/libcameraservice
diff options
context:
space:
mode:
authorEino-Ville Talvala <etalvala@google.com>2012-07-20 18:30:37 -0700
committerEino-Ville Talvala <etalvala@google.com>2012-07-20 18:30:37 -0700
commit2267106c98f461b730c772a913da946c391a178c (patch)
tree64c4fe71a71405291467077ddceda6df768d2d92 /services/camera/libcameraservice
parent9e4c3db01ba4eb1e5acbed113f78a31374900df6 (diff)
downloadframeworks_av-2267106c98f461b730c772a913da946c391a178c.zip
frameworks_av-2267106c98f461b730c772a913da946c391a178c.tar.gz
frameworks_av-2267106c98f461b730c772a913da946c391a178c.tar.bz2
Camera2: Stop preview: Wait until HAL is drained
Once camera returns from stopPreview, all preview activity needs to have stopped. So wait until that's true. Bug: 6243944 Change-Id: Ifa6cf171bd69015883e26dafb1e49e5ac098025a
Diffstat (limited to 'services/camera/libcameraservice')
-rw-r--r--services/camera/libcameraservice/Camera2Client.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/services/camera/libcameraservice/Camera2Client.cpp b/services/camera/libcameraservice/Camera2Client.cpp
index a115ef4..f21a518 100644
--- a/services/camera/libcameraservice/Camera2Client.cpp
+++ b/services/camera/libcameraservice/Camera2Client.cpp
@@ -592,6 +592,7 @@ void Camera2Client::stopPreviewLocked() {
// TODO: Handle record stop here
case PREVIEW:
mDevice->setStreamingRequest(NULL);
+ mDevice->waitUntilDrained();
case WAITING_FOR_PREVIEW_WINDOW:
mState = STOPPED;
break;