[Bug 793224] gl: context persistence issue

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Feb 7 03:07:19 UTC 2018


https://bugzilla.gnome.org/show_bug.cgi?id=793224

Matthew Waters (ystreet00) <ystreet00 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ystreet00 at gmail.com

--- Comment #1 from Matthew Waters (ystreet00) <ystreet00 at gmail.com> ---
(In reply to Philippe Normand from comment #0)
> I have an issue where my custom playbin video sink (glupload !
> glcolorconvert ! appsink) loses its context when the video chain is removed
> from playsink while the whole pipeline goes to READY.
> 
> So rendering works fine on first run, the app handles the need-context
> message fine. On second run the gl elements try a context query, that fails.
> Then they try to post a need-context message but they have no bus associated
> yet, so that fails. Then a new display is created from
> gst_gl_ensure_element_data() and it's for the wrong platform (egl vs
> wayland).

wayland only works with egl. Do you mean glx vs egl or x11 vs wayland ?

There's also an issue of terminology. When you say GL context, do you mean the
GStreamer GL context created internally or an application provided GL context
(they are not the same thing).

I think the key thing here is that 'there is not bus associated yet' which
sounds problematic.  Is the lack of a bus a playsink/playbin or an application
issue.

> But even with all those failures, somehow rendering works if the pipeline
> goes to PLAYING again.

'somehow'?

> On third run rendering fails.

How exactly?

> As a workaround I can manually set the context on the video sink before
> going to PAUSED on second and following runs but shouldn't the gl context be
> automatically reused from the persistent element context?

The GL context is not a persistent resource so will be destroyed and recreated
on pipeline shutdown/restart which is also true if playsink sets the video sink
to NULL.  GstContext's are also removed from elements when set they are set to
NULL (or READY). I can't remember which.

I think in order to debug this in any sort of capacity, some logs are needed.
e.g. GST_DEBUG=3,gl*:7,*CONTEXT*:7

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list