[Bug 711155] wayland: add wl_drm support to wayland sink

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Tue Sep 15 19:30:15 PDT 2015


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

--- Comment #56 from Nicolas Dufresne (stormer) <nicolas.dufresne at collabora.co.uk> ---
(In reply to Benjamin Gaignard from comment #53)
> In gstreamer doc it is clear that allocators are one of the properties
> negotiated between elements:
> http://cgit.freedesktop.org/gstreamer/gstreamer/tree/docs/design/part-
> bufferpool.txt#n20

If you read attentively, allocator are specially useful to allocate buffer of
variable size (that the intention). The allocator type could be use, but an
allocator should work with the generic pools. Thus, allocators stored in the
query are expected to implement gst_allocator_alloc() and to allow selecting a
size and an alignment. This is not the case of the generic DMABUF allocator,
which does not implement the generic alloc method. So unless you can subclass
this allocator (I don't know if that was the intention here) and implement the
generic alloc method, I believe it's wrong to add this allocator there.

About the V4L2 interface, it works with fixed size allocation, it is thus
impossible for such an element to provide a DMABUF based allocator. For the
dumb buffer it makes sense. So, GstDMABUFAllocator as-is, is a no-go in the
allocation query. If that is possible, a subclass of it for the dumb buffer
would be perfectly suitable.

That leaves us with the need for another mechanism to advertise that
waylandsink (or waylanddmabufsink) implements the importer role. If we have an
HW or a compositor that don't support the dumb buffer, then we have a sink that
can only take the importer role, and in that case, the caps feature makes a lot
of sense, as without upstream providing memory of type DMABuf, nothing can
work. As soon as you're sink can take the exporting role, there exist fallback
path to make it work.

Ideally, for the v4l2 case, we'll also need a way to advertise that downstream
may have dmabuf exporter role only, so an upstream element with importer role
can take the right decision, but it's outside of the scope for wayland, hence
for this bug.

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