Merge remote-tracking branch 'origin/5.5.0' into 5.5

Change-Id: I5a5b387b93a4b9dbaa9710e78fd7bf1ca09aa3b3
This commit is contained in:
Liang Qi
2015-06-26 14:04:32 +02:00
22 changed files with 240 additions and 44 deletions

118
dist/changes-5.5.0 vendored Normal file
View File

@@ -0,0 +1,118 @@
Qt 5.5 introduces many new features and improvements as well as bugfixes
over the 5.4.x series. For more details, refer to the online documentation
included in this distribution. The documentation is also available online:
http://doc.qt.io/qt-5.5
The Qt version 5.5 series is binary compatible with the 5.4.x series.
Applications compiled for 5.4 will continue to run with 5.5.
Some of the changes listed in this file include issue tracking numbers
corresponding to tasks in the Qt Bug Tracker:
http://bugreports.qt.io/
Each of these identifiers can be entered in the bug tracker to obtain more
information about a particular change.
****************************************************************************
* Library *
****************************************************************************
QtMultimedia
------------
- Added QAbstractVideoFilter that serves as a base class for QML
video filtering elements that integrate compute, vision, and image
processing frameworks with VideoOutput.
- Added new QCameraViewfinderSettings class.
- [QTBUG-40571] Fixed memory leak in QAudioDecoder.
- Camera (QML):
* Added imageProcessing.colorFilter, viewfinder.minimumFrameRate and
viewfinder.maximumFrameRate properties.
* Added new supportedViewfinderResolutions() and
supportedViewfinderFrameRateRanges() methods.
* Exposure modes extended to support Action, Landscape, NightPortrait,
Theatre, Sunset, SteadyPhoto, Fireworks, Party, Candlelight, and
Barcode modes
- QCamera:
* Added support for viewfinder settings. In addition to the getter and
setter, supportedViewfinderSettings(),
supportedViewfinderResolutions(), supportedViewfinderFrameRateRanges()
and supportedViewfinderPixelFormats() can be used to query for
supported values.
* Fixed searchAndLock() and supportedLocks() functions which could not
work at all on some platforms.
- QCameraExposure:
* Exposure modes extended to support Action, Landscape, NightPortrait,
Theatre, Sunset, SteadyPhoto, Fireworks, Party, Candlelight, and
Barcode modes
- QCameraImageProcessing:
* Added support for color filters.
****************************************************************************
* Platform Specific Changes *
****************************************************************************
Android
-------
- Added support for additional camera exposure modes (see list in
QCameraExposure changes).
iOS / OS X
----------
- Improved camera support:
* Image capture settings, focus, flash, exposure (iOS only) and
zoom (iOS only) APIs are now functional.
* QVideoProbe can now be used with a QCamera.
- VideoOutput, when used with a MediaPlayer on iOS, can now be displayed
under other elements and supports shader effects and advanced
transformations.
- QMediaRecorder now uses the correct system default audio capture
device.
- [QTBUG-36175] QMediaPlayer and the QML Audio and Mediaplayer types can
now play media files stored in a Qt resource file.
- [QTBUG-37655] Fixed video capture on iOS.
- [QTBUG-39240] QMediaPlayer and the QML Audio and Mediaplayer types now
support volume and mute on iOS 7.0 and later.
- [QTBUG-42035] Fixed crash when capturing an image after changing the
active camera device.
Linux
-----
- Added support for GStreamer 1.0. The 0.10 series is still used by default
and Qt needs to be configured with '-gstreamer 1.0' to enable 1.0
support. If only GStreamer 1.0 is available on the system, the configure
script will automatically configure Qt with GStreamer 1.0 support.
- QCamera now supports exposure and white balance locks.
- Added support for additional camera exposure modes (see list in
QCameraExposure changes).
- Fixed QCameraImageCapture::supportedResolutions(),
QMediaRecorder::supportedResolutions() and
QMediaRecorder::supportedFrameRates() that could return empty lists.
- [QTBUG-46169] QVideoWidget now works with any windowing system. It was
previously only working with X11.
Windows
-------
- [QTBUG-45571] QAudioBuffer::startTime() now returns the time in the
correct time scale.
WinRT
-----
- [QTBUG-42263] QMediaPlayer and the QML Audio and Mediaplayer types can
now play media files stored in a Qt resource file.
- [QTBUG-44838] Fixed camera preview on Lumia 630.
- [QTBUG-45920] Fixed camera preview on Lumia 530.
- [QTBUG-45667] Fixed crash that could occur when using the camera
preview.

View File

@@ -1094,8 +1094,8 @@ QJSValue QDeclarativeCamera::supportedViewfinderFrameRateRanges(const QSize &res
int i = 0; int i = 0;
Q_FOREACH (const QCamera::FrameRateRange &frameRateRange, frameRateRanges) { Q_FOREACH (const QCamera::FrameRateRange &frameRateRange, frameRateRanges) {
QJSValue range = engine->newObject(); QJSValue range = engine->newObject();
range.setProperty(QStringLiteral("minimumFrameRate"), frameRateRange.first); range.setProperty(QStringLiteral("minimumFrameRate"), frameRateRange.minimumFrameRate);
range.setProperty(QStringLiteral("maximumFrameRate"), frameRateRange.second); range.setProperty(QStringLiteral("maximumFrameRate"), frameRateRange.maximumFrameRate);
supportedFrameRateRanges.setProperty(i++, range); supportedFrameRateRanges.setProperty(i++, range);
} }

View File

@@ -72,7 +72,7 @@ static bool qt_sizeLessThan(const QSize &s1, const QSize &s2)
static bool qt_frameRateRangeLessThan(const QCamera::FrameRateRange &s1, const QCamera::FrameRateRange &s2) static bool qt_frameRateRangeLessThan(const QCamera::FrameRateRange &s1, const QCamera::FrameRateRange &s2)
{ {
return s1.second < s2.second; return s1.maximumFrameRate < s2.maximumFrameRate;
} }
/*! /*!
@@ -1028,15 +1028,29 @@ void QCamera::unlock()
/*! /*!
\typedef QCamera::FrameRateRange \class QCamera::FrameRateRange
\inmodule QtMultimedia
\ingroup multimedia
\ingroup multimedia_camera
\since 5.5
This is a typedef for QPair<qreal, qreal>. \brief A FrameRateRange represents a range of frame rates as minimum and maximum rate.
A frame rate range contains a minimum and a maximum frame rate, respectively the first and If the minimum frame rate is equal to the maximum frame rate, the frame rate is fixed.
second element of the pair. If the minimum frame rate is equal to the maximum frame rate, the If not, the actual frame rate fluctuates between the minimum and the maximum.
frame rate is fixed. If not, the actual frame rate fluctuates between the minimum and the maximum.
\sa QCamera::supportedViewfinderFrameRateRanges(), QCameraViewfinderSettings
*/ */
/*!
\variable QCamera::FrameRateRange::minimumFrameRate
The minimum frame rate supported by the range, in frames per second.
*/
/*!
\variable QCamera::FrameRateRange::maximumFrameRate
The maximum frame rate supported by the range, in frames per second.
*/
/*! /*!
\enum QCamera::State \enum QCamera::State

View File

@@ -77,7 +77,21 @@ class Q_MULTIMEDIA_EXPORT QCamera : public QMediaObject
Q_ENUMS(LockType) Q_ENUMS(LockType)
Q_ENUMS(Position) Q_ENUMS(Position)
public: public:
typedef QPair<qreal, qreal> FrameRateRange; struct FrameRateRange
{
Q_DECL_CONSTEXPR FrameRateRange() Q_DECL_NOTHROW
: minimumFrameRate(0)
, maximumFrameRate(0)
{ }
Q_DECL_CONSTEXPR FrameRateRange(qreal minimum, qreal maximum) Q_DECL_NOTHROW
: minimumFrameRate(minimum)
, maximumFrameRate(maximum)
{ }
qreal minimumFrameRate;
qreal maximumFrameRate;
};
enum Status { enum Status {
UnavailableStatus, UnavailableStatus,
@@ -237,6 +251,14 @@ private:
Q_DECLARE_OPERATORS_FOR_FLAGS(QCamera::LockTypes) Q_DECLARE_OPERATORS_FOR_FLAGS(QCamera::LockTypes)
Q_DECL_CONSTEXPR Q_INLINE_TEMPLATE bool operator==(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2) Q_DECL_NOTHROW
{ return r1.minimumFrameRate == r2.minimumFrameRate && r1.maximumFrameRate == r2.maximumFrameRate; }
Q_DECL_CONSTEXPR Q_INLINE_TEMPLATE bool operator!=(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2) Q_DECL_NOTHROW
{ return !(r1 == r2); }
Q_DECLARE_TYPEINFO(QCamera::FrameRateRange, Q_PRIMITIVE_TYPE);
QT_END_NAMESPACE QT_END_NAMESPACE
Q_DECLARE_METATYPE(QCamera::State) Q_DECLARE_METATYPE(QCamera::State)

View File

@@ -136,32 +136,35 @@ QCameraViewfinderSettings &QCameraViewfinderSettings::operator=(const QCameraVie
} }
/*! /*!
Determines if \a other is of equal value to a viewfinder settings object. \relates QCameraViewfinderSettings
\since 5.5
Determines if \a lhs is of equal value to \a rhs.
Returns true if the settings objects are of equal value, and false if they Returns true if the settings objects are of equal value, and false if they
are not of equal value. are not of equal value.
*/ */
bool QCameraViewfinderSettings::operator==(const QCameraViewfinderSettings &other) const bool operator==(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs) Q_DECL_NOTHROW
{ {
return (d == other.d) || return (lhs.d == rhs.d) ||
(d->isNull == other.d->isNull && (lhs.d->isNull == rhs.d->isNull &&
d->resolution == other.d->resolution && lhs.d->resolution == rhs.d->resolution &&
qFuzzyCompare(d->minimumFrameRate, other.d->minimumFrameRate) && lhs.d->minimumFrameRate == rhs.d->minimumFrameRate &&
qFuzzyCompare(d->maximumFrameRate, other.d->maximumFrameRate) && lhs.d->maximumFrameRate == rhs.d->maximumFrameRate &&
d->pixelFormat == other.d->pixelFormat && lhs.d->pixelFormat == rhs.d->pixelFormat &&
d->pixelAspectRatio == other.d->pixelAspectRatio); lhs.d->pixelAspectRatio == rhs.d->pixelAspectRatio);
} }
/*! /*!
Determines if \a other is of equal value to a viewfinder settings object. \fn bool operator!=(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs)
\relates QCameraViewfinderSettings
\since 5.5
Determines if \a lhs is of equal value to \a rhs.
Returns true if the settings objects are not of equal value, and false if Returns true if the settings objects are not of equal value, and false if
they are of equal value. they are of equal value.
*/ */
bool QCameraViewfinderSettings::operator!=(const QCameraViewfinderSettings &other) const
{
return !(*this == other);
}
/*! /*!
Identifies if a viewfinder settings object is uninitalized. Identifies if a viewfinder settings object is uninitalized.

View File

@@ -34,10 +34,12 @@
#ifndef QCAMERAVIEWFINDERSETTINGS_H #ifndef QCAMERAVIEWFINDERSETTINGS_H
#define QCAMERAVIEWFINDERSETTINGS_H #define QCAMERAVIEWFINDERSETTINGS_H
#include <QtCore/qsharedpointer.h>
#include <QtMultimedia/qtmultimediadefs.h> #include <QtMultimedia/qtmultimediadefs.h>
#include <QtMultimedia/qvideoframe.h> #include <QtMultimedia/qvideoframe.h>
#include <QtCore/qshareddata.h>
#include <QtCore/qsize.h>
QT_BEGIN_NAMESPACE QT_BEGIN_NAMESPACE
class QCameraViewfinderSettingsPrivate; class QCameraViewfinderSettingsPrivate;
@@ -51,9 +53,14 @@ public:
~QCameraViewfinderSettings(); ~QCameraViewfinderSettings();
QCameraViewfinderSettings& operator=(const QCameraViewfinderSettings &other); QCameraViewfinderSettings& operator=(const QCameraViewfinderSettings &other);
bool operator==(const QCameraViewfinderSettings &other) const; #ifdef Q_COMPILER_RVALUE_REFS
bool operator!=(const QCameraViewfinderSettings &other) const; QCameraViewfinderSettings &operator=(QCameraViewfinderSettings &&other) Q_DECL_NOTHROW
{ swap(other); return *this; }
#endif
void swap(QCameraViewfinderSettings &other) Q_DECL_NOTHROW { d.swap(other.d); }
friend Q_MULTIMEDIA_EXPORT bool operator==(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs) Q_DECL_NOTHROW;
bool isNull() const; bool isNull() const;
QSize resolution() const; QSize resolution() const;
@@ -78,6 +85,11 @@ public:
private: private:
QSharedDataPointer<QCameraViewfinderSettingsPrivate> d; QSharedDataPointer<QCameraViewfinderSettingsPrivate> d;
}; };
Q_DECLARE_SHARED(QCameraViewfinderSettings)
inline bool operator!=(const QCameraViewfinderSettings &lhs, const QCameraViewfinderSettings &rhs) Q_DECL_NOTHROW
{ return !operator==(lhs, rhs); }
QT_END_NAMESPACE QT_END_NAMESPACE

View File

@@ -62,7 +62,7 @@ class Q_MULTIMEDIA_EXPORT QAbstractVideoFilter : public QObject
Q_PROPERTY(bool active READ isActive WRITE setActive NOTIFY activeChanged) Q_PROPERTY(bool active READ isActive WRITE setActive NOTIFY activeChanged)
public: public:
QAbstractVideoFilter(QObject *parent = 0); explicit QAbstractVideoFilter(QObject *parent = 0);
~QAbstractVideoFilter(); ~QAbstractVideoFilter();
bool isActive() const; bool isActive() const;

View File

@@ -157,7 +157,7 @@ void AVFCameraFlashControl::cameraStateChanged(QCamera::State newState)
bool AVFCameraFlashControl::applyFlashSettings() bool AVFCameraFlashControl::applyFlashSettings()
{ {
Q_ASSERT(m_session->state() == QCamera::ActiveState); Q_ASSERT(m_session->requestedState() == QCamera::ActiveState);
AVCaptureDevice *captureDevice = m_session->videoCaptureDevice(); AVCaptureDevice *captureDevice = m_session->videoCaptureDevice();
if (!captureDevice) { if (!captureDevice) {

View File

@@ -789,7 +789,7 @@ void DSCameraSession::disconnectGraph()
static bool qt_frameRateRangeGreaterThan(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2) static bool qt_frameRateRangeGreaterThan(const QCamera::FrameRateRange &r1, const QCamera::FrameRateRange &r2)
{ {
return r1.second > r2.second; return r1.maximumFrameRate > r2.maximumFrameRate;
} }
void DSCameraSession::updateSourceCapabilities() void DSCameraSession::updateSourceCapabilities()
@@ -896,8 +896,8 @@ void DSCameraSession::updateSourceCapabilities()
Q_FOREACH (const QCamera::FrameRateRange &frameRateRange, frameRateRanges) { Q_FOREACH (const QCamera::FrameRateRange &frameRateRange, frameRateRanges) {
QCameraViewfinderSettings settings; QCameraViewfinderSettings settings;
settings.setResolution(resolution); settings.setResolution(resolution);
settings.setMinimumFrameRate(frameRateRange.first); settings.setMinimumFrameRate(frameRateRange.minimumFrameRate);
settings.setMaximumFrameRate(frameRateRange.second); settings.setMaximumFrameRate(frameRateRange.maximumFrameRate);
settings.setPixelFormat(pixelFormat); settings.setPixelFormat(pixelFormat);
m_supportedViewfinderSettings.append(settings); m_supportedViewfinderSettings.append(settings);

View File

@@ -56,7 +56,7 @@
using namespace Microsoft::WRL; using namespace Microsoft::WRL;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
#define BREAK_IF_FAILED(msg) RETURN_IF_FAILED(msg, break) #define BREAK_IF_FAILED(msg) RETURN_IF_FAILED(msg, break)
#define CONTINUE_IF_FAILED(msg) RETURN_IF_FAILED(msg, continue) #define CONTINUE_IF_FAILED(msg) RETURN_IF_FAILED(msg, continue)
@@ -408,3 +408,5 @@ void QWinRTAbstractVideoRendererControl::present()
QVideoFrame frame(d->videoBuffer, d->format.frameSize(), d->format.pixelFormat()); QVideoFrame frame(d->videoBuffer, d->format.frameSize(), d->format.pixelFormat());
d->surface->present(frame); d->surface->present(frame);
} }
QT_END_NAMESPACE

View File

@@ -68,7 +68,7 @@ using namespace ABI::Windows::Media::Devices;
using namespace ABI::Windows::Media::MediaProperties; using namespace ABI::Windows::Media::MediaProperties;
using namespace ABI::Windows::Storage::Streams; using namespace ABI::Windows::Storage::Streams;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
#define RETURN_VOID_AND_EMIT_ERROR(msg) \ #define RETURN_VOID_AND_EMIT_ERROR(msg) \
if (FAILED(hr)) { \ if (FAILED(hr)) { \
@@ -134,6 +134,7 @@ public:
hr = deviceInfo->get_SystemSku(deviceModel.GetAddressOf()); hr = deviceInfo->get_SystemSku(deviceModel.GetAddressOf());
Q_ASSERT_SUCCEEDED(hr); Q_ASSERT_SUCCEEDED(hr);
m_flags |= bufferLockRequired(L"NOKIA RM-976", deviceModel); m_flags |= bufferLockRequired(L"NOKIA RM-976", deviceModel);
m_flags |= bufferLockRequired(L"NOKIA RM-1019", deviceModel);
#endif #endif
} }
@@ -852,3 +853,5 @@ HRESULT QWinRTCameraControl::onRecordLimitationExceeded(IMediaCapture *)
setState(QCamera::LoadedState); setState(QCamera::LoadedState);
return S_OK; return S_OK;
} }
QT_END_NAMESPACE

View File

@@ -65,7 +65,7 @@ using namespace ABI::Windows::Media::MediaProperties;
using namespace ABI::Windows::Storage::Streams; using namespace ABI::Windows::Storage::Streams;
using namespace ABI::Windows::Graphics::Imaging; using namespace ABI::Windows::Graphics::Imaging;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
#define wchar(str) reinterpret_cast<const wchar_t *>(str.utf16()) #define wchar(str) reinterpret_cast<const wchar_t *>(str.utf16())
@@ -299,3 +299,5 @@ HRESULT QWinRTCameraImageCaptureControl::onCaptureCompleted(IAsyncAction *asyncI
return S_OK; return S_OK;
} }
QT_END_NAMESPACE

View File

@@ -37,7 +37,7 @@
#include "qwinrtcamerainfocontrol.h" #include "qwinrtcamerainfocontrol.h"
#include "qwinrtvideodeviceselectorcontrol.h" #include "qwinrtvideodeviceselectorcontrol.h"
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
QWinRTCameraInfoControl::QWinRTCameraInfoControl(QObject *parent) QWinRTCameraInfoControl::QWinRTCameraInfoControl(QObject *parent)
: QCameraInfoControl(parent) : QCameraInfoControl(parent)
@@ -53,3 +53,5 @@ int QWinRTCameraInfoControl::cameraOrientation(const QString &deviceName) const
{ {
return QWinRTVideoDeviceSelectorControl::cameraOrientation(deviceName); return QWinRTVideoDeviceSelectorControl::cameraOrientation(deviceName);
} }
QT_END_NAMESPACE

View File

@@ -46,7 +46,7 @@
#include <QtMultimedia/QVideoDeviceSelectorControl> #include <QtMultimedia/QVideoDeviceSelectorControl>
#include <QtMultimedia/QImageEncoderControl> #include <QtMultimedia/QImageEncoderControl>
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
class QWinRTCameraServicePrivate class QWinRTCameraServicePrivate
{ {
@@ -103,3 +103,5 @@ void QWinRTCameraService::releaseControl(QMediaControl *control)
{ {
Q_UNUSED(control); Q_UNUSED(control);
} }
QT_END_NAMESPACE

View File

@@ -45,7 +45,7 @@
#include <wrl.h> #include <wrl.h>
using namespace Microsoft::WRL; using namespace Microsoft::WRL;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
class D3DVideoBlitter class D3DVideoBlitter
{ {
@@ -210,3 +210,5 @@ void QWinRTCameraVideoRendererControl::discardBuffers()
for (ComPtr<IMF2DBuffer> &buffer : d->buffers) for (ComPtr<IMF2DBuffer> &buffer : d->buffers)
buffer.Reset(); buffer.Reset();
} }
QT_END_NAMESPACE

View File

@@ -55,7 +55,7 @@
#include <wrl.h> #include <wrl.h>
using namespace Microsoft::WRL; using namespace Microsoft::WRL;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
#define QT_WINRT_MEDIAPLAYER_STREAM_ID "__qtmultimedia_winrt_player_stream" #define QT_WINRT_MEDIAPLAYER_STREAM_ID "__qtmultimedia_winrt_player_stream"
@@ -892,3 +892,5 @@ void QWinRTMediaPlayerControl::finishRead()
Q_D(QWinRTMediaPlayerControl); Q_D(QWinRTMediaPlayerControl);
d->streamProvider->finishRead(); d->streamProvider->finishRead();
} }
QT_END_NAMESPACE

View File

@@ -41,7 +41,7 @@
struct IMFMediaEngineClassFactory; struct IMFMediaEngineClassFactory;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
class QVideoRendererControl; class QVideoRendererControl;
@@ -96,4 +96,6 @@ private:
Q_DECLARE_PRIVATE(QWinRTMediaPlayerControl) Q_DECLARE_PRIVATE(QWinRTMediaPlayerControl)
}; };
QT_END_NAMESPACE
#endif // QWINRTMEDIAPLAYERCONTROL_H #endif // QWINRTMEDIAPLAYERCONTROL_H

View File

@@ -47,7 +47,7 @@
using namespace Microsoft::WRL; using namespace Microsoft::WRL;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
class QWinRTMediaPlayerServicePrivate class QWinRTMediaPlayerServicePrivate
{ {
@@ -104,3 +104,5 @@ void QWinRTMediaPlayerService::releaseControl(QMediaControl *control)
if (control == d->player) if (control == d->player)
d->player->deleteLater(); d->player->deleteLater();
} }
QT_END_NAMESPACE

View File

@@ -54,7 +54,7 @@
#include <wrl.h> #include <wrl.h>
using namespace Microsoft::WRL; using namespace Microsoft::WRL;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
template <typename T> template <typename T>
class D3DDeviceLocker class D3DDeviceLocker
@@ -149,3 +149,5 @@ bool QWinRTPlayerRendererControl::render(ID3D11Texture2D *texture)
RETURN_FALSE_IF_FAILED("Failed to transfer video frame to DXGI surface"); RETURN_FALSE_IF_FAILED("Failed to transfer video frame to DXGI surface");
return true; return true;
} }
QT_END_NAMESPACE

View File

@@ -42,7 +42,7 @@
#include "qwinrtcameraservice.h" #include "qwinrtcameraservice.h"
#include "qwinrtvideodeviceselectorcontrol.h" #include "qwinrtvideodeviceselectorcontrol.h"
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
QMediaService *QWinRTServicePlugin::create(QString const &key) QMediaService *QWinRTServicePlugin::create(QString const &key)
{ {
@@ -102,3 +102,5 @@ QByteArray QWinRTServicePlugin::defaultDevice(const QByteArray &service) const
return QByteArray(); return QByteArray();
} }
QT_END_NAMESPACE

View File

@@ -39,7 +39,7 @@
#include <QtMultimedia/QMediaServiceProviderPlugin> #include <QtMultimedia/QMediaServiceProviderPlugin>
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
class QWinRTServicePlugin : public QMediaServiceProviderPlugin class QWinRTServicePlugin : public QMediaServiceProviderPlugin
, public QMediaServiceFeaturesInterface , public QMediaServiceFeaturesInterface
@@ -68,4 +68,6 @@ public:
QByteArray defaultDevice(const QByteArray &service) const Q_DECL_OVERRIDE; QByteArray defaultDevice(const QByteArray &service) const Q_DECL_OVERRIDE;
}; };
QT_END_NAMESPACE
#endif // QWINRTSERVICEPLUGIN_H #endif // QWINRTSERVICEPLUGIN_H

View File

@@ -55,7 +55,7 @@ typedef ITypedEventHandler<DeviceWatcher *, DeviceInformation *> DeviceInformati
typedef ITypedEventHandler<DeviceWatcher *, DeviceInformationUpdate *> DeviceInformationUpdateHandler; typedef ITypedEventHandler<DeviceWatcher *, DeviceInformationUpdate *> DeviceInformationUpdateHandler;
typedef ITypedEventHandler<DeviceWatcher *, IInspectable *> DeviceEnumerationCompletedHandler; typedef ITypedEventHandler<DeviceWatcher *, IInspectable *> DeviceEnumerationCompletedHandler;
QT_USE_NAMESPACE QT_BEGIN_NAMESPACE
static QString deviceName(IDeviceInformation *device) static QString deviceName(IDeviceInformation *device)
{ {
@@ -386,3 +386,5 @@ void QWinRTVideoDeviceSelectorControl::setSelectedDevice(int index)
emit selectedDeviceChanged(deviceName(d->selectedDevice)); emit selectedDeviceChanged(deviceName(d->selectedDevice));
} }
} }
QT_END_NAMESPACE