diff options
author | Lars Knoll <lars.knoll@qt.io> | 2021-03-02 13:11:36 +0100 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2021-03-16 07:41:44 +0000 |
commit | 5671ab651d9c938a0ff2df3a9c0baef9891e7e23 (patch) | |
tree | 4c5c6fde332af93b3d5f5cb4198df1ee0668434a /src/plugins | |
parent | e7702afc9dfa6e69b1b05d68a38248ccc6b6dd87 (diff) |
Move HandleType and MapMode from QAbstractVideoBuffer to QVideoFrame
QAbstractVideoBuffer is a class that is only required inside our
implementation, so we can make it private. This change prepares
for it.
Change-Id: I4ba4542c1eab742f2fc93231e2e5063dbc5d5e94
Reviewed-by: Doris Verria <doris.verria@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/plugins')
4 files changed, 5 insertions, 5 deletions
diff --git a/src/plugins/videonode/imx6/qsgvivantevideomaterial.cpp b/src/plugins/videonode/imx6/qsgvivantevideomaterial.cpp index 2e6c712e3..b238dff4f 100644 --- a/src/plugins/videonode/imx6/qsgvivantevideomaterial.cpp +++ b/src/plugins/videonode/imx6/qsgvivantevideomaterial.cpp @@ -176,7 +176,7 @@ GLuint QSGVivanteVideoMaterial::vivanteMapping(QVideoFrame vF) clearTextures(); } - if (vF.map(QAbstractVideoBuffer::ReadOnly)) { + if (vF.map(QVideoFrame::ReadOnly)) { if (mMappable) { if (!mBitsToTextureMap.contains(vF.bits())) { diff --git a/src/plugins/videonode/imx6/qsgvivantevideonode.h b/src/plugins/videonode/imx6/qsgvivantevideonode.h index 2796f1e44..1d2f3d342 100644 --- a/src/plugins/videonode/imx6/qsgvivantevideonode.h +++ b/src/plugins/videonode/imx6/qsgvivantevideonode.h @@ -51,7 +51,7 @@ public: ~QSGVivanteVideoNode(); QVideoFrame::PixelFormat pixelFormat() const { return mFormat.pixelFormat(); } - QAbstractVideoBuffer::HandleType handleType() const { return QAbstractVideoBuffer::NoHandle; } + QVideoFrame::HandleType handleType() const { return QVideoFrame::NoHandle; } void setCurrentFrame(const QVideoFrame &frame, FrameFlags flags); static const QMap<QVideoFrame::PixelFormat, GLenum>& getVideoFormat2GLFormatMap(); diff --git a/src/plugins/videonode/imx6/qsgvivantevideonodefactory.cpp b/src/plugins/videonode/imx6/qsgvivantevideonodefactory.cpp index 55ed57c10..a4982ad46 100644 --- a/src/plugins/videonode/imx6/qsgvivantevideonodefactory.cpp +++ b/src/plugins/videonode/imx6/qsgvivantevideonodefactory.cpp @@ -42,10 +42,10 @@ #include <QtGui/QGuiApplication> QList<QVideoFrame::PixelFormat> QSGVivanteVideoNodeFactory::supportedPixelFormats( - QAbstractVideoBuffer::HandleType handleType) const + QVideoFrame::HandleType handleType) const { const bool isWebGl = QGuiApplication::platformName() == QLatin1String("webgl"); - if (!isWebGl && handleType == QAbstractVideoBuffer::NoHandle) + if (!isWebGl && handleType == QVideoFrame::NoHandle) return QSGVivanteVideoNode::getVideoFormat2GLFormatMap().keys(); else return QList<QVideoFrame::PixelFormat>(); diff --git a/src/plugins/videonode/imx6/qsgvivantevideonodefactory.h b/src/plugins/videonode/imx6/qsgvivantevideonodefactory.h index dfb6a0123..6dd068d55 100644 --- a/src/plugins/videonode/imx6/qsgvivantevideonodefactory.h +++ b/src/plugins/videonode/imx6/qsgvivantevideonodefactory.h @@ -50,7 +50,7 @@ public: Q_PLUGIN_METADATA(IID QSGVideoNodeFactoryInterface_iid FILE "imx6.json") Q_INTERFACES(QSGVideoNodeFactoryInterface) - QList<QVideoFrame::PixelFormat> supportedPixelFormats(QAbstractVideoBuffer::HandleType handleType) const; + QList<QVideoFrame::PixelFormat> supportedPixelFormats(QVideoFrame::HandleType handleType) const; QSGVideoNode *createNode(const QVideoSurfaceFormat &format); }; #endif // QSGVIDEONODEFACTORY_VIVANTE_H |