playbin - blank areas on screen and various questions

philippe renon philippe_renon at yahoo.fr
Thu Apr 13 13:31:13 UTC 2017


Try to add this to your widget:
void <YourWidgetClassName>::paintEvent(QPaintEvent *event)
{
    overlay->expose();
}


void <YourWidgetClassName>::resizeEvent(QResizeEvent *event)
{
    overlay->expose();
}

Where overlay is your GstVideoOverlay.

These two overrides are essential.
The paintEvent() is needed when gstreamer is not playing the video.
The resizeEvent() is needed to let gstreamer know that the widget size has changed.

Philippe.
 

    Le Jeudi 13 avril 2017 15h26, philippe renon <philippe_renon at yahoo.fr> a écrit :
 

 Try to add this to your widget:
void MyClass::paintEvent(QPaintEvent *event)
{
    overlay->expose();
} 

    Le Jeudi 13 avril 2017 15h01, Harry McKame <mckameh at wanadoo.fr> a écrit :
 

 Philippe, I have looked at your code and it's much too heavy for me.
I have copied the following lines but that's not enough - the blank spaces are still there:

    setAutoFillBackground(true);
    setAttribute(Qt::WA_OpaquePaintEvent, false);
    setAttribute(Qt::WA_PaintOnScreen, false);

If GStreamer does not use all the overlay's window, why does it never paint the rest ?
Is my only solution left is to resize the display window to be exactly covered by the video?
_______________________________________________
gstreamer-devel mailing list
gstreamer-devel at lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


   

   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20170413/3db59129/attachment-0001.html>


More information about the gstreamer-devel mailing list