diff options
author | Yoann Lopes <yoann.lopes@theqtcompany.com> | 2015-11-19 15:32:48 +0100 |
---|---|---|
committer | Yoann Lopes <yoann.lopes@theqtcompany.com> | 2015-12-03 09:40:28 +0000 |
commit | 5ed9b6d6d77c420ea02aac5f01af1e9f85731f1b (patch) | |
tree | 4262b7e0d0ad4ee31d6e3ce2cf55035bdde3be93 | |
parent | 8dc46cef05d901bb48f0d87e19a8b35b5e70757e (diff) |
AVFoundation: fix setting up the video capture session.
Because of an incorrect 'if' condition, the video capture session was
set up twice when starting the camera.
Change-Id: I4211a8c77ab9b8086628fb0f12fb28842de830cf
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
-rw-r--r-- | src/plugins/avfoundation/camera/avfmediarecordercontrol.mm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/avfoundation/camera/avfmediarecordercontrol.mm b/src/plugins/avfoundation/camera/avfmediarecordercontrol.mm index 412dab76c..115d70864 100644 --- a/src/plugins/avfoundation/camera/avfmediarecordercontrol.mm +++ b/src/plugins/avfoundation/camera/avfmediarecordercontrol.mm @@ -359,7 +359,7 @@ void AVFMediaRecorderControl::setupSessionForCapture() } } else if (m_connected && (!m_cameraControl->captureMode().testFlag(QCamera::CaptureVideo) - || m_session->state() != QCamera::ActiveState)) { + || m_session->state() == QCamera::UnloadedState)) { [captureSession removeOutput:m_movieOutput]; |