Revert "clutter/offscreen-effect: Use the paint volume origin as the FBO offset"

This change broke the color picker in gnome-shell, let's revert it for
now until a correct solution can be figured out.

This reverts commit 0bace8dbde.

Closes https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/3494

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1645>
This commit is contained in:
Jonas Dreßler 2020-12-16 19:39:35 +01:00 committed by Marge Bot
parent 446839c0d0
commit 7de5f79ddb

View File

@ -298,7 +298,7 @@ clutter_offscreen_effect_pre_paint (ClutterEffect *effect,
ClutterOffscreenEffect *self = CLUTTER_OFFSCREEN_EFFECT (effect);
ClutterOffscreenEffectPrivate *priv = self->priv;
CoglFramebuffer *offscreen;
ClutterActorBox box;
ClutterActorBox raw_box, box;
ClutterActor *stage;
graphene_matrix_t projection, modelview;
const ClutterPaintVolume *volume;
@ -334,18 +334,19 @@ clutter_offscreen_effect_pre_paint (ClutterEffect *effect,
ClutterPaintVolume mutable_volume;
_clutter_paint_volume_copy_static (volume, &mutable_volume);
_clutter_paint_volume_get_bounding_box (&mutable_volume, &box);
_clutter_paint_volume_get_bounding_box (&mutable_volume, &raw_box);
clutter_paint_volume_free (&mutable_volume);
}
else
{
clutter_actor_get_allocation_box (priv->actor, &box);
clutter_actor_get_allocation_box (priv->actor, &raw_box);
}
box = raw_box;
_clutter_actor_box_enlarge_for_effects (&box);
priv->fbo_offset_x = box.x1;
priv->fbo_offset_y = box.y1;
priv->fbo_offset_x = box.x1 - raw_box.x1;
priv->fbo_offset_y = box.y1 - raw_box.y1;
clutter_actor_box_scale (&box, ceiled_resource_scale);
clutter_actor_box_get_size (&box, &target_width, &target_height);