diff options
author | Lars Knoll <lars.knoll@qt.io> | 2021-04-13 20:25:36 +0200 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2021-04-16 11:01:56 +0000 |
commit | 063047a6f81065bde4a2b844f48a7d99ba3133af (patch) | |
tree | f2abba4c5fe66508f7fd8f6378c5e97c2af7cd39 /src/imports | |
parent | 1730d400c8010f5e3f34d1df44e9be5262ac62c9 (diff) |
Register the C++ based API under new names to be able to test it
The C++ classes will get exposed directly and replace the wrapper
classes that got used in Qt 5.x. Expose them under their name
prefixed with 'N' for now to test them. They will eventually
replace the old implementation.
Change-Id: Ia79ee788552a2253b6a310a1ff57d004ecf00adc
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Doris Verria <doris.verria@qt.io>
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/multimedia/multimedia.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/imports/multimedia/multimedia.cpp b/src/imports/multimedia/multimedia.cpp index 014e07cdb..031a834f1 100644 --- a/src/imports/multimedia/multimedia.cpp +++ b/src/imports/multimedia/multimedia.cpp @@ -44,6 +44,9 @@ #include "qsoundeffect.h" #include "qmediaplayer.h" #include "qmediametadata.h" +#include "qcamera.h" +#include "qmediacapturesession.h" +#include "qmediaencoder.h" #include <private/qdeclarativevideooutput_p.h> @@ -104,6 +107,12 @@ public: qmlRegisterType<QDeclarativePlaylist>(uri, 6, 0, "Playlist"); qmlRegisterType<QDeclarativePlaylistItem>(uri, 6, 0, "PlaylistItem"); + // ### new replacement types + qmlRegisterType<QMediaCaptureSession>(uri, 6, 0, "CaptureSession"); + qmlRegisterType<QMediaEncoder>(uri, 6, 0, "MediaEncoder"); + qmlRegisterType<QCamera>(uri, 6, 0, "NCamera"); + qmlRegisterUncreatableType<QCameraExposure>(uri, 6, 0, "NCameraExposure", tr("CameraExposure is provided by Camera")); + // The minor version used to be the current Qt 5 minor. For compatibility it is the last // Qt 5 release. qmlRegisterModule(uri, 6, 0); |