[clutter/clutter-1.22] actor: Use the real opacity when clearing the stage



commit af498519e983914419f9ff66c48012a5787729a1
Author: Emmanuele Bassi <ebassi gnome org>
Date:   Thu Apr 30 12:40:39 2015 +0100

    actor: Use the real opacity when clearing the stage
    
    The paint opacity for a top level is always overridden to be the full
    value, since it's a composited value and we want to paint our scene.
    
    When clearing the stage framebuffer, though, we want to use the actual
    opacity, if ClutterStage:use-alpha is set.
    
    (cherry picked from commit 8b8aa0b4927bc865b08b77b4e28237da0ff8597c)
    
    Signed-off-by: Emmanuele Bassi <ebassi gnome org>

 clutter/clutter-actor.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/clutter/clutter-actor.c b/clutter/clutter-actor.c
index df43e4d..6b9f484 100644
--- a/clutter/clutter-actor.c
+++ b/clutter/clutter-actor.c
@@ -3593,13 +3593,19 @@ clutter_actor_paint_node (ClutterActor     *actor,
 
       if (clutter_stage_get_use_alpha (CLUTTER_STAGE (actor)))
         {
-          bg_color.alpha = clutter_actor_get_paint_opacity_internal (actor)
+          bg_color.alpha = priv->opacity
                          * priv->bg_color.alpha
                          / 255;
         }
       else
         bg_color.alpha = 255;
 
+      CLUTTER_NOTE (PAINT, "Stage clear color: (%d, %d, %d, %d)",
+                    bg_color.red,
+                    bg_color.green,
+                    bg_color.blue,
+                    bg_color.alpha);
+
       clear_flags = COGL_BUFFER_BIT_DEPTH;
       if (!clutter_stage_get_no_clear_hint (CLUTTER_STAGE (actor)))
         clear_flags |= COGL_BUFFER_BIT_COLOR;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]