diff options
author | VaL Doroshchuk <valentyn.doroshchuk@qt.io> | 2018-02-27 13:23:27 +0100 |
---|---|---|
committer | VaL Doroshchuk <valentyn.doroshchuk@qt.io> | 2019-05-15 11:50:54 +0000 |
commit | 26767a8ebe355f55a7fd5aaa9ec947dea1b6ce29 (patch) | |
tree | cd625783652c171011da74dab0b9116f75b55f74 /src/qtmultimediaquicktools/qsgvideonode_texture.cpp | |
parent | 5ed9d1d830b90c5d5093cc7ca4a5c7cd5b15240c (diff) |
Gstreamer: Introduce support of OpenGL plugin
Since uploading to gl texture is quite performance-wise operation
introduced integration of opengl plugin which can provide a way
to avoid uploading to texture on each draw on qt's side.
Which potentially fixes some performance issues especially on embedded devices.
Added glupload and glcolorconvert gst elements to pipeline.
For qml apps current opengl context is provided to the gst plugin to share opengl data with.
It allows at the end to just use gl textures that created and filled inside the gst.
For overlay apps, glimagesink element is added.
Requires gstreamer-gl-1.0 to be installed.
Since this plugin is almost always available, so enabling it by default will break behavior of current pipeline
and might introduce some side effects.
Thus also provided QT_GSTREAMER_USE_OPENGL_PLUGIN env var to explicitly enable OpenGL features from gst.
After this change video frames will be texture based.
But it is still possible to map frames to download their data.
In case if the video surface does not support gl textures,
glmemory will be anyway requested, which will lead to uploading data, downloading
and uploading it again to textures in scene graph video node.
Task-number: QTBUG-66162
Change-Id: I32044ba0bf0c0cf90434d72f8991ad00927e1380
Reviewed-by: Christian Strømme <christian.stromme@qt.io>
Diffstat (limited to 'src/qtmultimediaquicktools/qsgvideonode_texture.cpp')
-rw-r--r-- | src/qtmultimediaquicktools/qsgvideonode_texture.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/qtmultimediaquicktools/qsgvideonode_texture.cpp b/src/qtmultimediaquicktools/qsgvideonode_texture.cpp index f5545afc7..318e4cef5 100644 --- a/src/qtmultimediaquicktools/qsgvideonode_texture.cpp +++ b/src/qtmultimediaquicktools/qsgvideonode_texture.cpp @@ -58,6 +58,7 @@ QList<QVideoFrame::PixelFormat> QSGVideoNodeFactory_Texture::supportedPixelForma pixelFormats.append(QVideoFrame::Format_ARGB32); pixelFormats.append(QVideoFrame::Format_BGR32); pixelFormats.append(QVideoFrame::Format_BGRA32); + pixelFormats.append(QVideoFrame::Format_ABGR32); } return pixelFormats; |