-
Bug
-
Resolution: Invalid
-
P2: Important
-
None
-
6.2.2
-
None
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.