GNOME Bugzilla – Bug 751484
compositor: refactor in order to have alpha sources blended over non alpha ones
Last modified: 2018-11-03 13:36:44 UTC
The idea is to be able to compose a YUV with a AYUV into a YUV without having to convert twice. It could be useful to use porter/duff operations for this. Needs some refactoring in compositor, in order to select the proper blend function based on sources opacities.
Example pipeline : gst-launch-1.0 -evv videotestsrc is-live=true ! 'video/x-raw,format=NV12,width=1280,height=720' ! \ compositor name=mux ! 'video/x-raw,format=NV12,width=1280,height=720' ! fakesink \ videotestsrc is-live=true ! 'video/x-raw,format=ARGB,width=320,height=240' ! mux. The objective is to avoid videconversion from NV12 to ARGB or ARGB to NV12. Right now, it is not working, as downstream has no alpha and one of sinks has.
I agree we need this feature. I believe the compositor only implements SRC_OVER, where having SRC_COPY is wanted. I think completing the existing (but very limited) blit API would be the "ideal" way forward. I would be fine though if we implement more dynamic blit operation due to time constraint. A first step would be to collect the need, and what HW and API already do, and draft an usable and dynamic API.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/264.