• Daniel van Vugt's avatar
    clutter/offscreen-effect: Use the paint volume origin as the FBO offset · 0bace8db
    Daniel van Vugt authored
    Before now it was assumed that the only negative local coordinates would
    be those introduced by `_clutter_actor_box_enlarge_for_effects`, and we
    used the difference for `fbo_offset_x/y`. But that was misguided (of me)
    because gnome-shell can give us paint volumes at negative coordinates too,
    like when rendering `box-shadow` on the top or left edge of an actor.
    The maximum extents of negative coordinates we might need to render are
    in fact the (enlarged) left and top edges of the paint volume. So use
    those as the FBO offset. This places the actor's local origin correctly
    within the FBO and thus also ensures it's not over-clipped at the edges
    of the FBO, which now line up with the enlarged extents of the paint
    This fixes one third of
    The other fixes required are !1053 and gnome-shell!1417.
    Part-of: <GNOME/mutter!1538>
clutter-offscreen-effect.c 22.8 KB