[mutter] shaped-texture: Make sure to set the texture tower's texture



commit 18cfcc0221157be134cca674357a7bcd4aebac2e
Author: Jasper St. Pierre <jstpierre mecheye net>
Date:   Wed Feb 5 15:35:00 2014 -0500

    shaped-texture: Make sure to set the texture tower's texture
    
    This was part of the Wayland branch that I forgot to cherry-pick properly.

 src/compositor/meta-shaped-texture.c |   11 ++++++++---
 1 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/src/compositor/meta-shaped-texture.c b/src/compositor/meta-shaped-texture.c
index d1d2053..a22aa2e 100644
--- a/src/compositor/meta-shaped-texture.c
+++ b/src/compositor/meta-shaped-texture.c
@@ -567,8 +567,7 @@ meta_shaped_texture_set_create_mipmaps (MetaShapedTexture *stex,
     {
       CoglTexture *base_texture;
       priv->create_mipmaps = create_mipmaps;
-      base_texture = create_mipmaps ?
-        COGL_TEXTURE (priv->texture) : NULL;
+      base_texture = create_mipmaps ? priv->texture : NULL;
       meta_texture_tower_set_base_texture (priv->paint_tower, base_texture);
     }
 }
@@ -728,7 +727,13 @@ set_cogl_texture (MetaShapedTexture *stex,
       clutter_actor_queue_relayout (CLUTTER_ACTOR (stex));
     }
 
-  clutter_actor_queue_redraw (CLUTTER_ACTOR (stex));
+  /* NB: We don't queue a redraw of the actor here because we don't
+   * know how much of the buffer has changed with respect to the
+   * previous buffer. We only queue a redraw in response to surface
+   * damage. */
+
+  if (priv->create_mipmaps)
+    meta_texture_tower_set_base_texture (priv->paint_tower, cogl_tex);
 }
 
 /**


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