diff options
author | Yoann Lopes <yoann.lopes@theqtcompany.com> | 2015-02-10 11:44:58 +0100 |
---|---|---|
committer | Yoann Lopes <yoann.lopes@theqtcompany.com> | 2015-02-10 13:12:20 +0000 |
commit | beba964dc412de78fad8fb0e3a9c8a20ff3c0399 (patch) | |
tree | b8e62b4bfea716e967570958dcd7872e87fde31c /src | |
parent | d3df85959b8e8ef90c512f1c9a8628f11167f7e6 (diff) |
Clarify documentation for QImageCapture's 'ready' property.
Unlike what was described in the documentation, it's not permissible to
call capture() while 'ready' or isReadyForCapture() is false. All
backends emit an error in that case.
Updated the documentation to reflect that behavior.
Change-Id: Icb326e65376b65eadd4c68b67e0ee30beddf1a04
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/imports/multimedia/qdeclarativecameracapture.cpp | 16 | ||||
-rw-r--r-- | src/multimedia/camera/qcameraimagecapture.cpp | 9 |
2 files changed, 11 insertions, 14 deletions
diff --git a/src/imports/multimedia/qdeclarativecameracapture.cpp b/src/imports/multimedia/qdeclarativecameracapture.cpp index ad90d976e..79121a28c 100644 --- a/src/imports/multimedia/qdeclarativecameracapture.cpp +++ b/src/imports/multimedia/qdeclarativecameracapture.cpp @@ -123,9 +123,8 @@ QDeclarativeCameraCapture::~QDeclarativeCameraCapture() This property holds a bool value indicating whether the camera is ready to capture photos or not. - If camera is not ready to capture image immediately, - the capture request is queued with all the related camera settings, - and the request will be executed as soon as possible. + Calling capture() while \e ready is \c false is not permitted and + results in an error. */ /*! @@ -134,11 +133,8 @@ QDeclarativeCameraCapture::~QDeclarativeCameraCapture() This property holds a bool value indicating whether the camera is ready to capture photos or not. - It's permissible to call capture() while the camera is active - regardless of the \e ready property value. - If camera is not ready to capture image immediately, - the capture request is queued with all the related camera settings, - and the request will be executed as soon as possible. + Calling capture() while \e ready is \c false is not permitted and + results in an error. */ bool QDeclarativeCameraCapture::isReadyForCapture() const { @@ -160,8 +156,10 @@ bool QDeclarativeCameraCapture::isReadyForCapture() const image processing parameters, so changes to camera paramaters after capture() is called do not affect previous capture requests. - CameraCapture::capture returns the capture requestId parameter, used with + capture() returns the capture requestId parameter, used with imageExposed(), imageCaptured(), imageMetadataAvailable() and imageSaved() signals. + + \sa ready */ int QDeclarativeCameraCapture::capture() { diff --git a/src/multimedia/camera/qcameraimagecapture.cpp b/src/multimedia/camera/qcameraimagecapture.cpp index cb0c26346..341317649 100644 --- a/src/multimedia/camera/qcameraimagecapture.cpp +++ b/src/multimedia/camera/qcameraimagecapture.cpp @@ -488,11 +488,8 @@ void QCameraImageCapture::setCaptureDestination(QCameraImageCapture::CaptureDest \property QCameraImageCapture::readyForCapture \brief whether the service is ready to capture a an image immediately. - It's permissible to call capture() while the camera status is QCamera::ActiveStatus - regardless of isReadyForCapture property value. - If camera is not ready to capture image immediately, - the capture request is queued with all the related camera settings - to be executed as soon as possible. + Calling capture() while \e readyForCapture is \c false is not permitted and + results in an error. */ bool QCameraImageCapture::isReadyForCapture() const @@ -528,6 +525,8 @@ bool QCameraImageCapture::isReadyForCapture() const QCameraImageCapture::capture returns the capture Id parameter, used with imageExposed(), imageCaptured() and imageSaved() signals. + + \sa isReadyForCapture() */ int QCameraImageCapture::capture(const QString &file) { |