Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c44cf627 authored by Nipun Kwatra's avatar Nipun Kwatra
Browse files

Call startPreview after stopping for mUseStillCameraForTimeLapse=true case.

In the case when stop is pressed after takePicture has been called
but the CAMERA_MSG_COMPRESSED_IMAGE message from camera has not yet
been received, preview was not getting restarted. The reason was that
CameraSource::stop sets the camera listener to NULL and hence the
dataCallback() function which handles the CAMERA_MSG_COMPRESSED_IMAGE
message and restarts preview never got called.

Change-Id: Ib8f3bb77d9eab1ed5a67798569025ea0d63d7fd4
parent 7d73206a
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -187,6 +187,7 @@ void CameraSourceTimeLapse::stopCameraRecording() {
    if (mUseStillCameraForTimeLapse) {
        void *dummy;
        pthread_join(mThreadTimeLapse, &dummy);
        CHECK_EQ(OK, mCamera->startPreview());
    } else {
        mCamera->stopRecording();
    }