[Cogl] [PATCH] cogl-gst: Smooth out issues with layering code

Plamena Manolova plamena.n.manolova at intel.com
Wed Apr 10 03:00:25 PDT 2013


This fixes a few bugs in the custom coversion and
the frame attachment code.
---
 cogl-gst/cogl-gst-video-sink.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/cogl-gst/cogl-gst-video-sink.c b/cogl-gst/cogl-gst-video-sink.c
index 03be970..a960567 100644
--- a/cogl-gst/cogl-gst-video-sink.c
+++ b/cogl-gst/cogl-gst-video-sink.c
@@ -636,14 +636,14 @@ cogl_gst_video_sink_attach_custom_conversion (CoglGstVideoSink *sink,
 
   snippet = NULL;
 
-  if (start > 0 && start != last_layer && modulate)
+  if (start > 0 && start != previous_layer && modulate)
     {
       src =
         g_strdup_printf ("cogl_layer = cogl_layer%i.rgba * %s (cogl_tex_coord%i_in.st);",
-                         last_layer, convertion_name, start);
+                         previous_layer, convertion_name, start);
       snippet = cogl_snippet_new (COGL_SNIPPET_HOOK_LAYER_FRAGMENT, NULL, src);
     }
-  else if (modulate)
+  else if (modulate && start == 0)
     {
       src = g_strdup_printf ("cogl_layer =  %s (cogl_tex_coord%i_in.st);",
                              convertion_name);
-- 
1.8.1.2

---------------------------------------------------------------------
Intel Corporation (UK) Limited
Registered No. 1134945 (England)
Registered Office: Pipers Way, Swindon SN3 1RJ
VAT No: 860 2173 47

This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.



More information about the Cogl mailing list