[Bug 749411] glcontext_egl should call eglTerminate to free resources for non EGL DISPLAY types

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon May 25 19:39:24 PDT 2015


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

--- Comment #15 from Jian Li <lj.qfy.sh at gmail.com> ---
(In reply to Matthew Waters from comment #14)
> (In reply to Jian Li from comment #13)
> > With this patch, I think we don't need to call eglTerminate. The whole
> > process will share the same display, so there is only one display
> > connection. When process quit, it will free the resources automatically,
> > correct?
> 
> The whole process was sharing the same display before, just through
> GstGLWindow instead of GstGLDisplay.  It's still advisable to call
> eglTerminate when you're done with EGL resources so you don't leak.

Yes, whole process share the same GstGLWindow, but in loop playback, when
destroy glimagesink, the GstGLWindow will be destroyed too, so that the wayland
display destroyed. If you didn't call eglTerminate, leak occurs.

If split display from window, the display will be stored in the GstContext,in
the whole process lifetime, only one display instance, this avoid resource
leak.

> 
> > Actually I don't know where to call this eglTerminate with current code
> > structure. If move eglGetDisplay into GstGLDisplayWayland, this will change
> > the returned display to egl display, not wayland display.
> 
> Yes, we need both native display and eglDisplay which is where the
> interface/GstStructure comes in.

-- 
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