[Bug 755072] vaapi: expose memory:DMABuf capsfeature

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Mon Jun 26 09:32:15 UTC 2017


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

--- Comment #81 from Julien Isorce <julien.isorce at gmail.com> ---
Sure, it is great anyway!

So I tried and I have a few remarks. For the caps feature did you try with
glimagesink patch from https://bugzilla.gnome.org/show_bug.cgi?id=774649 ?

Because if I apply that patch, it seems that vaapi does not respect the
gstglupload caps order/prefs. Indeed vaapih264dec ! glimagesink will negotiate
the DMABuf caps feature, whereas being ordered after the SystemMemory.

Can also be tested with:

vaapih264dec ! capsfilter caps="video/x-raw(memory:SystemMemory);
video/x-raw(memory:DMABuf)" ! glimagesink

Second remark, here
https://cgit.freedesktop.org/gstreamer/gstreamer-vaapi/tree/gst/vaapi/gstvaapipluginbase.c#n611
I would expect to be plugin->srcpad_can_dmabuf instead of the
!plugin->srcpad_can_dmabuf but actually shouldn't be passing TRUE always ? In
order to match the commit message
https://cgit.freedesktop.org/gstreamer/gstreamer-vaapi/commit/?id=f578515988ecf6c0ebaf920a94ea43b3fcf5c2a6

Can be tested with:

vaapih264dec ! capsfilter caps="video/x-raw(memory:SystemMemory)" ! glimagesink

Currently the decoder pushes dmabuf buffers despite being not mappable.

---- 

So without caps renegotiation support, which I am fine with it for now (again
what you did is already a great step further and might be enough after all), I
would expect that the pipeline:

vaapih264dec ! capsfilter caps="video/x-raw(memory:SystemMemory);
video/x-raw(memory:DMABuf)" ! glimagesink 

would just does not do any dmabuf at all. Because it will try dmabuf without
caps feature first and map will fail. But since it will not try to renegotiate,
it will not try to negotiate with the caps feature. So no dmabuf which is what
I would expect with current commits upstream (+gstglupload patch that adds the
caps feature)

The only way to do dmabuf with current upstream (+ gstglupload patch that adds
the caps feature) would be to add a capsfilter:

vaapih264dec ! capsfilter caps="video/x-raw(memory:DMABuf)" ! glimagesink
or
vaapih264dec ! capsfilter caps="video/x-raw(memory:DMABuf);
video/x-raw(memory:SystemMemory)" ! glimagesink (i.e. changing the order by
using a caps filter for custom usage for example)

Which would match what the commit message
https://cgit.freedesktop.org/gstreamer/gstreamer-vaapi/commit/?id=b6863e64b550af8b472eeb35520071ab7cc0d6eb
says :)

Thx !

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