[Bug 796640] Fix for a synchronization bug in 1.14.1 ext/qt/gstqsgtexture.cc

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Thu Jun 21 14:21:12 UTC 2018


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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #372742|none                        |needs-work
             status|                            |

--- Comment #11 from Matthew Waters (ystreet00) <ystreet00 at gmail.com> ---
Review of attachment 372742:
 --> (https://bugzilla.gnome.org/review?bug=796640&attachment=372742)

What you might be seeing is a use-before-release where qmlglsink releases the
buffer before Qt has drawn with it and could be written too by upstream. 
Fixing that involves keeping the buffer and/or gst_video_frame_map () alive
between successive bind()  calls (or error/destruction).

::: ext/qt/gstqsgtexture.cc
@@ +152,3 @@
+  *  since the memory in buffer_ is used by other threads
+  */
+  gst_gl_sync_meta_wait_cpu (sync_meta, this->qt_context_);

This is actually the wrong API to cause a wait and will cause a glFinish() (or
equivalent in GL fences) which is way to heavy handed for this.  The fact that
they're used by other threads/contexts does not matter in GPU space.

You only need to wait for the GPU to complete (of which there is already code
to do that).

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