diff options
author | VaL Doroshchuk <valentyn.doroshchuk@qt.io> | 2019-07-23 10:33:51 +0200 |
---|---|---|
committer | VaL Doroshchuk <valentyn.doroshchuk@qt.io> | 2019-07-23 10:33:51 +0200 |
commit | 14d6166b2790b37906fd76248d955659ff78622f (patch) | |
tree | f02ec37165b5ae47beb238aa23031e6e2106502f /tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp | |
parent | e99a2e1701179d0d28ef1d1eac696d480894f4bb (diff) | |
parent | 2eb0a98f1de07782004a5a4261cb5d2c46ca6d15 (diff) |
Merge branch 'dev' of git://code.qt.io/qt/qtmultimedia into wip/qt6
Change-Id: I91e8d902cd916ee16a2495da9bf40a34c6bc05d2
Diffstat (limited to 'tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp')
-rw-r--r-- | tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp b/tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp index 43dc52022..7ba631e58 100644 --- a/tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp +++ b/tests/auto/unit/qpaintervideosurface/tst_qpaintervideosurface.cpp @@ -730,16 +730,14 @@ void tst_QPainterVideoSurface::shaderSupportedFormat_data() QTest::addColumn<bool>("supportedPixelFormat"); QTest::addColumn<bool>("supportedFormat"); - QList<QPair<QPainterVideoSurface::ShaderType, QByteArray> > types; - - + const QPair<QPainterVideoSurface::ShaderType, QByteArray> types[] = { #if !defined(QT_OPENGL_ES) - types << qMakePair(QPainterVideoSurface::FragmentProgramShader, QByteArray("ARBfp: ")); + qMakePair(QPainterVideoSurface::FragmentProgramShader, QByteArray("ARBfp: ")), #endif - types << qMakePair(QPainterVideoSurface::GlslShader, QByteArray("GLSL: ")); + qMakePair(QPainterVideoSurface::GlslShader, QByteArray("GLSL: ")), + }; - QPair<QPainterVideoSurface::ShaderType, QByteArray> type; - foreach (type, types) { + for (const auto &type : types) { QTest::newRow((type.second + "rgb32 640x480").constData()) << type.first << QAbstractVideoBuffer::NoHandle @@ -952,14 +950,14 @@ void tst_QPainterVideoSurface::shaderPresent_data() QTest::addColumn<int>("bytesB"); QTest::addColumn<int>("bytesPerLineB"); - QList<QPair<QPainterVideoSurface::ShaderType, QByteArray> > types; + const QPair<QPainterVideoSurface::ShaderType, QByteArray> types[] = { #if !defined(QT_OPENGL_ES) - types << qMakePair(QPainterVideoSurface::FragmentProgramShader, QByteArray("ARBfp: ")); + qMakePair(QPainterVideoSurface::FragmentProgramShader, QByteArray("ARBfp: ")), #endif - types << qMakePair(QPainterVideoSurface::GlslShader, QByteArray("GLSL: ")); + qMakePair(QPainterVideoSurface::GlslShader, QByteArray("GLSL: ")), + }; - QPair<QPainterVideoSurface::ShaderType, QByteArray> type; - foreach (type, types) { + for (const auto &type : types) { QTest::newRow((type.second + "rgb32 -> argb32").constData()) << type.first << QVideoFrame::Format_RGB32 |