composite: Fix COW creation for Xinerama (v2)
authorAdam Jackson <ajax@redhat.com>
Thu, 7 Nov 2013 18:59:30 +0000 (13:59 -0500)
committerAdam Jackson <ajax@redhat.com>
Mon, 9 Dec 2013 18:20:36 +0000 (13:20 -0500)
commit1dd839a425adc6e5a1dc377003ed86a374d81f0b
tree28707bd90d730417aee5f06eebf364ce702cff67
parent8dbe456abae1a32fb6c5c74fa456bc7301cccabe
composite: Fix COW creation for Xinerama (v2)

Say you have two 800x600 screens left/right of each other.  A window
that's 200x200 at +700+0 in protocol coordinate space will appear to be
at -100+0 in the coordinate space of the right hand screen.  Put another
way: windows are in the coordinate space of their root window pixmap.

We weren't doing this translation for the COW, so when rendering came in
to it you'd see the top-left chunk of the COW on all screens.  Cool
effect and all, but wrong.

v2: Only translate when Xinerama is active [keithp]

Reviewed-by: Keith Packard <keithp@keithp.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
composite/compoverlay.c