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

Calling hide and show on QVideoWidget produces INVALID_MEDIA on video playback

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Invalid
    • Icon: P2: Important P2: Important
    • None
    • 6.2.2
    • Multimedia
    • None
    • Windows

      I'm trying to write a custom media player.  Part of the desired functionality is a text shown "No Video" when the media played back does not contain any video.

      I have attempted several ways to achieve this. The current one I'll put in code below attempts to hide and then show the video-widget, and display the message in the overloaded paintEvent-method of the custom QMainWindow-descendant.

      Other attempts included setting a different central widget, and then re-setting the video-widget. On top destroying and re-creating that widget, and setting it as video output. 

      So is there a prescribed way of doing this? The only thing I could found (in online discussions) was to use QGraphicsView. This works somewhat, however with 4K video material the framerate plummets visibly - probably due to the pixels being shoveled through memory too often. The approach is unusable because of that.

        1. qt_media_interface_controller.cpp
          3 kB
          Diez Roggisch
        2. qt_media_interface_controller.hpp
          1 kB
          Diez Roggisch
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            anrocha André De La Rocha (Inactive)
            __deets__ Diez Roggisch
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes