Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-113359

QVideoSink on QMediaPlayer without QRhi does not work

XMLWordPrintable

    • Android
    • 2023wk20FOQtforAndroid, 2023wk22FOQtforAndroid, 2023wk24FOQtforAndroid, 2023wk26FOQtforAndroid, 2023wk28FOQtforAndroid, 2023wk30FOQtforAndroid, 2023wk38FOQtforAndroid, 2023wk40FOQtforAndroid, 2023wk42FOQtforAndroid, 2023wk44FOQtforAndroid, 2023wk46FOQtforAndroid, 2023wk48FOQtforAndroid, 2023wk50FOQtforAndroid, 2023wk52FOQtforAndroid, 2024wk02FOQtforAndroid, 2024wk04FOQtforAndroid, 2024wk06FOQtforAndroid, 2024wk08FOQtforAndroid

      If you create a QMediaPlayer, then a QVideoSink, and forward frames from that to a video sink from a qquickvideooutput element, it does not work on android unless you also set the QRhi * on the video sink attached to the media player.

      Instead you see either a blank texture or in some cases the video output will render the global texture atlas instead. There is a need to do this sink redirect because QMediaPlayer only supports one video sink at the moment and if you want to render the same player in multiple places at once.

      Could this be fixed in Qt without the need to use private qt api calls? Supporting multiple sinks on a QMediaPlayer would be the ideal solution.

      To reproduce, please run the attached example project. It runs fine on Windows or Linux, but on Android, you need to change line #34 in main.cpp to make it work.

        1. qtbug_113359.zip
          2 kB
          Tuomas Vaarala
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            bartlomiejmoskal Bartlomiej Moskal
            tuomas.vaarala Tuomas Vaarala
            Votes:
            5 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes