summaryrefslogtreecommitdiffstats
path: root/src/multimedia/video/qvideoframe.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Update commercial license headers"v5.15.3-lts-lgplTarja Sundqvist2021-03-251-20/+20
| | | | | | | | | | | This reverts commit 80d46e3a5f64ff2456c40bdba63b6d5c69a32cdd. Revert of commercial license headers is required for Qt 5.15.3 opensource release. Task-number: QTBUG-91108 Change-Id: I5c64ffa120f916711e5cf01c828774f8456dec06 Reviewed-by: Akseli Salovaara <akseli.salovaara@qt.io>
* Update commercial license headersTarja Sundqvist2021-01-271-20/+20
| | | | | | | | | | | | | | | | Updated header.COMM to files in tqtc-qtmultimedia. Examples, tests or documentation files are not updated. The commercial license header may contain some additional lines so that its line count equals with the earlier license header. Reaso for this is that some autotests use hard coded line numbers and a change in the line count causes failures in tests. Task-number: QTQAINFRA-4171 Change-Id: I86ebf7c3653b55983cefff246c0cb019cbcda8c4 Reviewed-by: Akseli Salovaara <akseli.salovaara@qt.io>
* Revert "Map QVideoFrame::Format_Y8=>QImage::Format_Grayscale8 in QVideoFrame"Andy Shaw2020-11-301-4/+1
| | | | | | | | | | | | This reverts commit 2b96c113cf7057b556856149114999b973b3f2c2, due to the fact that it introduces a problem with existing cameras on Windows. So reverting for now until a fix can be found. Change-Id: Ica59c8a68de7aecf6a4ebd1bd044363e9acefd93 Reviewed-by: Liang Qi <liang.qi@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 67d1ff140e60e3372d05fc7af2cf85de891a31f0) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Map QVideoFrame::Format_Y8=>QImage::Format_Grayscale8 in QVideoFrameVaL Doroshchuk2020-06-021-1/+4
| | | | | | | | Fixes: QTBUG-52455 Change-Id: I30582582935ae0a2c5094db995cba83b62adc767 Reviewed-by: Liang Qi <liang.qi@qt.io> (cherry picked from commit 2b96c113cf7057b556856149114999b973b3f2c2) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
* Introduce QVideoFrame::image()VaL Doroshchuk2019-10-311-4/+4
| | | | | | | | | | | | | Since QVideoFrame::pixelFormat's do not 100% match QImage::Format's, introducing converstion function. Returns an image based on current frame. Converts data if needed to supported QImage format. Change-Id: I3331578c01cf9c999a380efc4a83bf9eddb07901 (cherry picked from commit 93f966335e1ed8ed47b7e8b32452d43c2f8a7bb1) Reviewed-by: Daniel Smith <Daniel.Smith@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* Fix qConvertFuncs to respect QVideoFrame::Format_YUV422PVal Doroshchuk2019-10-081-3/+3
| | | | | | | After changing sequence in QVideoFrame, need to fix qConvertFuncs Change-Id: Ie022676a66d9c47a1b89cf5ef61c2146921a2a0b Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
* Add YUV422P format support to QVideoFrame and declarative rendererTomasz Olszak2019-05-101-3/+14
| | | | | | | | | [ChangeLog] Added QVideoFrame::Format_YUV422P. Change-Id: If7741db00cf0b628d7fc4b1cd3a6e424e0f8e2c0 Reviewed-by: VaL Doroshchuk <valentyn.doroshchuk@qt.io> Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* Introduce QVideoFrame::buffer()VaL Doroshchuk2019-02-041-0/+9
| | | | | | | | Returns video buffer if available. Is useful when need to get an access to impl specific data. Change-Id: I6b9855397db2396ed0a76835d083be0457721f9b Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
* multimedia: modernize by using nullptrJochen Seemann2019-01-041-11/+11
| | | | | | Change-Id: Id1084fec084b972aaa1d2389ee56ee831a821172 Reviewed-by: André Hartmann <aha_1980@gmx.de> Reviewed-by: VaL Doroshchuk <valentyn.doroshchuk@qt.io>
* Fix conversion from QVideoFrame to QImage to respect bytesPerLineVal Doroshchuk2018-11-301-1/+1
| | | | | | | | | | | | | | Since bytes per line can vary and be more than width * bytes in pixel, it should be respected in the conversion. This issue could be observed with ANGLE and IDirect3DSurface9 surfaces. Where IDirect3DSurface9::LockRect returns D3DLOCKED_RECT with Pitch (number bytes in the row) higher than width * bytes in pixel. Task-number: QTBUG-71610 Change-Id: Ic62c50382d9006b0f214626f34f2eb4fd70e8377 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Christian Stromme <christian.stromme@qt.io>
* Setup QVideoFrame::Format_ABGR32Val Doroshchuk2018-11-091-0/+4
| | | | | | | Task-number: QTBUG-69968 Change-Id: I241978969b655b3e716fa9cf5a91fe17f266032f Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* Android: Change video frame format from BGR32 to ABGR32Val Doroshchuk2018-10-031-0/+3
| | | | | | | | | | | | When mapping video frame, data will be downloaded to QImage from frame buffer with QImage::Format_RGBX8888 which is XBGR32 in Little Endian. Thus added new pixel format QVideoFrame::Format_ABGR32. Changed QVideoFrame::Format_BGR32 to QVideoFrame::Format_ABGR32. Task-number: QTBUG-69968 Change-Id: I0f58d1a5b5cbdb5ab48ee5ad4d75f9b62f516333 Reviewed-by: Christian Stromme <christian.stromme@qt.io>
* Replace Q_NULLPTR with nullptrKevin Funk2017-09-271-19/+19
| | | | | Change-Id: I3b7601b4a97f8a2b1d2da6ef134f1577846ba713 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Updated license headersAntti Kokko2016-01-191-14/+20
| | | | | | | | | | | From Qt 5.7 -> LGPL v2.1 isn't an option anymore, see http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/ Updated license headers to use new LGPL header instead of LGPL21 one (in those files which will be under LGPL v3) Change-Id: I324f65c61171f36641472964d095d72e452afb3a Reviewed-by: Jani Heikkinen <jani.heikkinen@theqtcompany.com> Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* Add private API for conversion from QVideoFrame to QImage.Yoann Lopes2015-10-201-0/+126
| | | | | | | | | | The Android plugin had a function to convert from NV21 to RGB32. It's now moved to the Qt Multimedia library and it supports additional source formats. It could be further improved with more SIMD code, it could then become a public API. Change-Id: Ibee349027048a263a1a7ea74dc51237f7747912c Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
* Fix debug stream operators.Friedemann Kleint2015-04-071-44/+49
| | | | | | | | | | - Use QDebugStateSaver to restore space setting in stream operators instead of returning dbg.space() which breaks formatting on streams that already have nospace() set. - Fix some single character string constants, streamline code. Change-Id: I18ae7324b172ea801aa9b5fe56ddf6fe527fdde9 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Update copyright headersAntti Kokko2015-02-121-7/+7
| | | | | | | | | Qt copyrights are now in The Qt Company, so we could update the source code headers accordingly. In the same go we should also fix the links to point to qt.io. Change-Id: I1c6faa4f59f8eca54f01ef20941fa60161dd7872 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Add video filtering support to VideoOutputLaszlo Agocs2015-02-031-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | Add the QAbstractVideoFilter base class and integrate it with VideoOutput. This can be used to perform arbitrary filtering or image processing on the frames of a video stream of a VideoOutput element right before the OpenGL texture is provided to the scenegraph by the video node. This opens up the possibility to integrate computer vision frameworks or accelerated image processing with Qt Quick applications that display video streams using Qt Multimedia. Conceptually it is somewhat similar to QVideoProbe, this approach however allows modifying the frame, in real time with tight integration to the scenegraph node, and targets Qt Quick meaning setting up the filter and processing the results of the computations happen completely in QML. [ChangeLog] Added QAbstractVideoFilter that serves as a base class for QML video filtering elements that integrate compute, vision, and image processing frameworks with VideoOutput. Change-Id: Ice1483f8c2daec5a43536978627a7bbb64549480 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Support byte ordered QImage formats in pixelFormatFromImageFormatLaszlo Agocs2015-01-091-0/+3
| | | | | | | For QVideoFrame purposes they are equivalent. Change-Id: I776c60aa8ca848e58499bbd0c1fc25c457d46ef6 Reviewed-by: Yoann Lopes <yoann.lopes@theqtcompany.com>
* Update license headers and add new license filesAntti Kokko2014-08-241-19/+11
| | | | | | | | | - Renamed LICENSE.LGPL to LICENSE.LGPLv21 - Added LICENSE.LGPLv3 & LICENSE.GPLv2 - Removed LICENSE.GPL Change-Id: Ied06887225df341064c12bcc14c259ae74116f2e Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
* Support per-plane strides and data offsets in QVideoFrame.Andrew den Exter2014-07-081-21/+153
| | | | | | | | | | | | Since just adding a new virtual isn't binary compatible add a new derivative type with a virtual member and connect it up through a virtual in the private class. [ChangeLog] Support for per-plane strides and data offsets in QVideoFrame. Task-number: QTBUG-38345 Change-Id: I1974c2b0b454d130e17971ce549031259d61f9cd Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Merge remote-tracking branch 'origin/5.3' into devSergio Ahumada2014-06-141-11/+6
|\ | | | | | | | | | | | | Conflicts: .qmake.conf Change-Id: Iecd8d7b94e52a8981526b12cffa40e99870ba62f
| * Use Q_CONSTRUCTOR_FUNCTION macro to register multimedia meta types.Yoann Lopes2014-05-301-11/+6
| | | | | | | | | | | | Task-number: QTBUG-39131 Change-Id: I2493c9e3e6f0065d0441a74ff240d7d91fbe059c Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* | Removed debug operator autotests.Yoann Lopes2014-03-261-1/+1
|/ | | | | | | | | | For QVideoFrame, QAudioFormat and QVideoSurfaceFormat. There's no point in testing the formatting of the debug operator. These tests can break every time there's a change in QDebug's output policy. Change-Id: I2349b4722a428bc4c56ca58b13889790e86df4c1 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Update copyright year in Digia's license headersSergio Ahumada2013-01-101-1/+1
| | | | | | Change-Id: Ia8c1c38aba1544603fada8c414cc856f365fd15b Reviewed-by: Akseli Salovaara <akseli.salovaara@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
* Change copyrights from Nokia to DigiaIikka Eklund2012-09-241-24/+24
| | | | | | | | | Change copyrights and license headers from Nokia to Digia Change-Id: Id77334cfb15de096941c88e32d04ca07b4eb4709 Reviewed-by: Janne Anttila <janne.anttila@digia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com> Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* Added QAbstractVideoBuffer::release virtual methodDmytro Poplavskiy2012-06-071-1/+2
| | | | | | | | | | | | | | It's useful when the buffer pool stores QAbstractVideoBuffer instances instead of underlying system buffers and allows to avoid reallocation of QAbstractVideoBuffer instances. The default implementation deletes the buffer, so this change is source compatible. Change-Id: I7dadd7dac529748b5eb33e5aa7c2d0578b8b1634 Reviewed-by: Lev Zelenskiy <lev.zelenskiy@nokia.com> Reviewed-by: Jonas Rabbe <jonas.rabbe@gmail.com> Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
* Fixed not initialized QVideoFrame mappedCount memberDmytro Poplavskiy2012-05-301-0/+1
| | | | | Change-Id: Ic0b915df120222b0bb440698c010f0e83ccce8c3 Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
* Change uses of {to,from}Ascii to {to,from}Latin1Thiago Macieira2012-05-041-1/+1
| | | | | | | | | | This operation should be a no-op anyway, since at this point in time, the fromAscii and toAscii functions simply call their fromLatin1 and toLatin1 counterparts. Task-number: QTBUG-21872 Change-Id: Ic591779a3431999c007fb0ff362c7e25ce54097e Reviewed-by: Jonas Rabbe <jonas.rabbe@gmail.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I20e5215108c6ebd5f8474fed5c3665118e4791e6 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update obsolete contact address.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: Ie8cd560b6d9a2c6e552b6be1ad8bc96c80a6535c Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix up a few doc issuesMichael Goddard2012-01-171-0/+3
| | | | | | | | | | | | | * lingering references to Mobility * missing group tags on some classes meant they went missing * put classes into functional groups as well (e.g. audio, camera) * added some of the qdoc files to OTHER_FILES so they show up in Creator There are still a lot of warnings since it seems like qdoc is not processing the controls directory. Change-Id: I036f8826ae63f8273b3e649cb32c091d964ce830 Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Remove antiquated \since lines in docs.Michael Goddard2012-01-161-31/+0
| | | | | | | They aren't useful in the case of QtMultimedia{Kit} Change-Id: If1b0b6625763c85907fb05beb9c440046472ddef Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Add a metaData property to QVideoFrame.Michael Goddard2012-01-131-3/+50
| | | | | Change-Id: I6614cd86e3e1e170277bfc751222b5b42cb657eb Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com>
* Polish the video documentation a bit.Michael Goddard2012-01-131-25/+53
| | | | | | Change-Id: I7f76f710b64379ae6935cd86aed37914a7f85d0b Reviewed-by: Dmytro Poplavskiy <dmytro.poplavskiy@nokia.com> Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Update year in Nokia copyright headers.Jason McDonald2012-01-121-1/+1
| | | | | | | Update headers from before 2011 that were missed in the previous commit. Change-Id: Ib0fd91a39ffc57117fe01280e34519c3f914fac0 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Allow nested read only maps of QVideoFrame.Dmytro Poplavskiy2011-11-281-6/+48
| | | | | | | | It's useful when video frame is accessed from multiple places like display and encoding. Change-Id: I8af175c780783216d8b7717cdf0744ad9bc95348 Reviewed-by: Michael Goddard <michael.goddard@nokia.com>
* Add qRegisterMetaTypes for the public Q_DECLARE_METATYPEs.Michael Goddard2011-11-091-1/+3
| | | | | | | | Also turned qtmedianamespace.qdoc into a cpp file so I could stick the qRegisterMetaTypes into it. Change-Id: Idd6d3e2f348f1ed45b0a35ce180d023a170e8625 Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Declare more metatypes and debug operators.Michael Goddard2011-11-021-5/+108
| | | | | | | | | | | Nearly all of the multimedia metatypes used in the auto tests are now declared properly, and a large number of the types have debug operators as well. Removed the superfluous decls as well. Change-Id: I42cfe37562db0c71d9811b4577fc326a3326ccc9 Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Improve video test coverage and debugging output.Michael Goddard2011-10-071-15/+82
| | | | | | | | | | | Added a few debug operators for some useful enums, and added tests for them. One or two other features not really tested. Change-Id: Idffec6ade1d4e05dbf72f3dc47dfc0d01ddddf8b Reviewed-on: http://codereview.qt-project.org/6201 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>
* Rename QtMultimediaKit to QtMultimedia.Michael Goddard2011-10-071-0/+776
There are a few legacy bits left in place so it passes CI, and then qt5.git etc can be updated. Change-Id: I6b082e50e6958c72fdabc2974992e16d90dafa3a Reviewed-on: http://codereview.qt-project.org/5368 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Jonas Rabbe <jonas.rabbe@nokia.com>