AVFCameraExposureControl - exposure control for iOS
Exposure control, version for AVFoundation plugin (this code is using quite a new API, iOS >=8 only). Change-Id: I6871a758e8dfb98ab46b66d91a44142163e0bb44 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
This commit is contained in:
@@ -41,6 +41,7 @@
|
||||
|
||||
#include <QtCore/qvariant.h>
|
||||
#include <QtCore/qdebug.h>
|
||||
#include <QtCore/qsysinfo.h>
|
||||
|
||||
#include "avfcameraservice.h"
|
||||
#include "avfcameracontrol.h"
|
||||
@@ -56,6 +57,7 @@
|
||||
#include "avfimagecapturecontrol.h"
|
||||
#include "avfmediavideoprobecontrol.h"
|
||||
#include "avfcamerafocuscontrol.h"
|
||||
#include "avfcameraexposurecontrol.h"
|
||||
|
||||
#include <private/qmediaplaylistnavigator_p.h>
|
||||
#include <qmediaplaylist.h>
|
||||
@@ -75,8 +77,12 @@ AVFCameraService::AVFCameraService(QObject *parent):
|
||||
m_metaDataControl = new AVFCameraMetaDataControl(this);
|
||||
m_recorderControl = new AVFMediaRecorderControl(this);
|
||||
m_imageCaptureControl = new AVFImageCaptureControl(this);
|
||||
|
||||
m_cameraFocusControl = new AVFCameraFocusControl(this);
|
||||
m_cameraExposureControl = 0;
|
||||
#if defined(Q_OS_IOS) && QT_IOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__IPHONE_8_0)
|
||||
if (QSysInfo::MacintoshVersion >= QSysInfo::MV_IOS_8_0)
|
||||
m_cameraExposureControl = new AVFCameraExposureControl(this);
|
||||
#endif
|
||||
}
|
||||
|
||||
AVFCameraService::~AVFCameraService()
|
||||
@@ -96,6 +102,7 @@ AVFCameraService::~AVFCameraService()
|
||||
delete m_metaDataControl;
|
||||
delete m_cameraControl;
|
||||
delete m_cameraFocusControl;
|
||||
delete m_cameraExposureControl;
|
||||
|
||||
delete m_session;
|
||||
}
|
||||
@@ -124,6 +131,9 @@ QMediaControl *AVFCameraService::requestControl(const char *name)
|
||||
if (qstrcmp(name, QCameraImageCaptureControl_iid) == 0)
|
||||
return m_imageCaptureControl;
|
||||
|
||||
if (qstrcmp(name, QCameraExposureControl_iid) == 0)
|
||||
return m_cameraExposureControl;
|
||||
|
||||
if (qstrcmp(name, QCameraFocusControl_iid) == 0)
|
||||
return m_cameraFocusControl;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user