From 2dc9e0dc2941a1f805e71a656585037ced0ed721 Mon Sep 17 00:00:00 2001 From: Neil Roberts Date: Sat, 27 Nov 2010 16:27:59 +0000 Subject: [PATCH] ClutterOffscreenEffect: Don't throw away the material for a new actor When a new actor is set for ClutterOffscreenEffect it would throw away the old material. I don't think there is anything specifically tied to the actor in the material so throwing away just loses Cogl's cached state about the material. This ends up relinking the shader every time a new actor is set in ClutterShaderEffect. http://bugzilla.clutter-project.org/show_bug.cgi?id=2454 --- clutter/clutter-offscreen-effect.c | 6 ------ 1 file changed, 6 deletions(-) diff --git a/clutter/clutter-offscreen-effect.c b/clutter/clutter-offscreen-effect.c index ebfc45d..b6e6900 100644 --- a/clutter/clutter-offscreen-effect.c +++ b/clutter/clutter-offscreen-effect.c @@ -111,12 +111,6 @@ clutter_offscreen_effect_set_actor (ClutterActorMeta *meta, priv->offscreen = COGL_INVALID_HANDLE; } - if (priv->target != COGL_INVALID_HANDLE) - { - cogl_handle_unref (priv->target); - priv->target = COGL_INVALID_HANDLE; - } - /* we keep a back pointer here, to avoid going through the ActorMeta */ priv->actor = clutter_actor_meta_get_actor (meta); } -- 2.7.4