QVideoWidget running in worker thread
-
I am a little bit stucked with idea to add a QVideoWidget to QWidget which is located in my MainWindow UI. I am very interested to know how to move VideoWidget to worker thread which will change the content of QWidget in my MainWindow UI by using signals and slots. I am aware that that sending a big data over signals and slots is not good practice, but I am interested to hear your advice on how to implement this idea? I will be playing video based on this example.
-
every QWidget MUST reside in the GUI-thread (= main thread)
No way around -
@raven-worx But what will happen if I have two videowidgets and I play them in the same time, one will be blocked, am I right?
-
@Lazar-Urosevic
what makes you think that? Then also the GUI would be blocked when only 1 video widget is used?
But it is a matter of 2 mins to give it a try ;) -
So you say that I can have two QWidgets in my MainWindow GUI (main thread) and inside them run QVideoWidget example at the same time?
-
@Lazar-Urosevic Yes, you can have two QVideoWidgets at the same time. Why should one of them block? And why not just try it?