compositor: Fix partial repaints
authorAnder Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>
Tue, 30 Oct 2012 15:44:01 +0000 (17:44 +0200)
committerKristian Høgsberg <krh@bitplanet.net>
Tue, 30 Oct 2012 17:53:51 +0000 (13:53 -0400)
commit5df8ecac5d31467122a9d8bda6241d5957ae6848
tree40c8db2d4a3a55fd4680f2e020e135e222e8e991
parentd2fbb3870cfaea623a87ba28c9587676bbdc93f7
compositor: Fix partial repaints

Partial repaints have been broken since the introduction of the atomic
surface updates. The problem was that surface_commit would set the
geometry dirty flag unconditionally, causing transform updates on every
frame which would in turn cause weston_surface_damage_below() to damage
the whole surface area.

This patch changes this so that flag is only set if the pending buffer
has a different size, the location of the surface changed or the opaque
region changed.

Note that changing the opaque region will cause a full repaint of the
affected surface, because of the transform update.

https://bugs.freedesktop.org/show_bug.cgi?id=56538
src/compositor.c