[Bug 761059] kmssink: add new plugin and element

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Wed Feb 24 00:56:43 UTC 2016


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

--- Comment #43 from Nicolas Dufresne (stormer) <nicolas.dufresne at collabora.co.uk> ---
(In reply to Philipp Zabel from comment #39)
> Increasing to 2 causes it to stutter, alternating between the first two
> buffers. After increasing min buffers to 3, I get smooth playback with the
> correct frames.
> 
> So that works, but I suspect that even when getting the minimal buffers from
> the offered pool, things will still break when the source decides to change
> the order or adds additional buffers due to latency.

(I don't know the terms in kms, sorry, just giving the theory here)

When you import a DMABuf, you have to make sure to keep the upstream DMABuf
alive until it is no longer being used as a scannout. This requires a minimum
amount of buffers. When correctly implemented, 2 "importation buffers" are
enough, but might be slow due to cache being badly used. In an ideal situation,
you need 1 "importation buffer" per DMABuf, so you use the same envelope for
the same DMABuf. This is probably what you get "by accident" when setting it to
3. This should not rely on bufferpool order or anything. In GL space, it's an
EGLImage that represent the "importation buffer". What we do, is that we cache
which ELGImage was used for which upstream DMABuf. This solves the cache issue,
we can then bind the EGLImage to a texture to obtain a rendering.

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