1
0
Fork 0
mutter-performance-source/cogl-gst
Neil Roberts 2543a86ba1 cogl-gst-video-sink: Premultiply the colors coming from the video
Commit 99a53c82e9ab0a1e5 removed the internal format argument when
uploading a video frame to a texture so that the format will just be
determined automatically from the image format. However this also
leaves the premultiplied state at the default and the default is TRUE.
That means that when we upload RGBA data Cogl will do a premultiplied
conversion on the CPU. We probably don't want to be putting a CPU
conversion in the way of video frames so this patch changes it to set
the premultiplied state to FALSE on the textures and then do the
premultiplied conversion in the shader.

This is particularly important for AYUV which uses the alpha channel
for the V component so doing a premultiplied conversion on the CPU
just creates garbage and messes up the image.

The RGB and RGBA renderers have each been split into two; one that
uses GLSL and one that uses a regular pipeline. The RGBA pipeline
without GLSL is then changed to use 2 layers so we that we can do the
premultiplied conversion in the second layer with a special layer
combine string.

Reviewed-by: Robert Bragg <robert@linux.intel.com>
(cherry picked from commit 07a57f26596c72507035369c90ed6d62568330b5)
2014-01-31 12:42:03 +00:00
..
cogl-gst-1.0.pc.in Consistently name cogl-gst pkg-config files 2014-01-09 16:03:17 +00:00
cogl-gst-2.0-experimental.pc.in Consistently name cogl-gst pkg-config files 2014-01-09 16:03:17 +00:00
cogl-gst-plugin.c cogl-gst-plugin: Use a real version number and web address 2013-06-21 19:01:35 +01:00
cogl-gst-video-sink.c cogl-gst-video-sink: Premultiply the colors coming from the video 2014-01-31 12:42:03 +00:00
cogl-gst-video-sink.h cogl-gst-video-sink: Premultiply the colors coming from the video 2014-01-31 12:42:03 +00:00
cogl-gst.h Include CoglGst 2013-06-21 18:57:24 +01:00
cogl-gst.pc.in cogl-gst: pedantic typo fix in pkg-config description 2013-06-21 18:59:49 +01:00
Makefile.am Consistently name cogl-gst pkg-config files 2014-01-09 16:03:17 +00:00