offscreen-effect: Add public accessor for target size

The OffscreenEffect class needs to expose a way for sub-classes to
track the size of FBO it creates, in case it has to do some geometry
deformations like the DeformEffect sub-classes.

Let's move the private symbol we used internally in 1.6 to fix
DeformEffect to the list of public symbols of OffscreenEffect.

http://bugzilla.clutter-project.org/show_bug.cgi?id=2570
This commit is contained in:
Emmanuele Bassi
2011-02-28 14:31:59 +00:00
parent e2b5762571
commit 0c83e6a59a
5 changed files with 39 additions and 14 deletions

View File

@ -184,7 +184,10 @@ clutter_deform_effect_paint_target (ClutterOffscreenEffect *effect)
actor = clutter_actor_meta_get_actor (CLUTTER_ACTOR_META (effect));
opacity = clutter_actor_get_paint_opacity (actor);
if (!_clutter_offscreen_effect_get_target_size (effect, &width, &height))
/* if we don't have a target size, fall back to the actor's
* allocation, though wrong it might be
*/
if (!clutter_offscreen_effect_get_target_size (effect, &width, &height))
clutter_actor_get_size (actor, &width, &height);
for (i = 0; i < priv->y_tiles + 1; i++)