[PATCH] EXA: Use correct coordinate system for calculating Composite fallback region.
Michel Dänzer
michel at daenzer.net
Thu Dec 3 07:59:09 PST 2009
On Wed, 2009-12-02 at 09:49 -0800, Keith Packard wrote:
> On Wed, 2 Dec 2009 11:48:11 +0100, Michel Dänzer <michel at daenzer.net> wrote:
>
> > + if (pSrc->pDrawable) {
> > + xSrc += pSrc->pDrawable->x;
> > + ySrc += pSrc->pDrawable->y;
> > + }
> > +
> > + if (pMask && pMask->pDrawable) {
> > + xMask += pMask->pDrawable->x;
> > + yMask += pMask->pDrawable->y;
> > + }
> > +
>
> I haven't read through the code carefully yet, but if there are
> transforms involved, then this computation is incorrect -- source
> coordinates are in the post-transform space. Given that the next line
> calls miComputeCompositeRegion, that would also be incorrect in the
> presence of source or mask transforms (yay!).
(Oddly enough, fbWalkCompositeRegion() does the same thing...)
Ugh, sounds like it'll be tricky to get this 100% correct for source
pictures with ->pDrawable->x/y != 0...
Fortunately though, that's a relatively academic issue compared to the
real problem occurring with window destination pictures. As a first
step, would you accept a patch with only the destination coordinate
adjustments?
--
Earthling Michel Dänzer | http://www.vmware.com
Libre software enthusiast | Debian, X and DRI developer
More information about the xorg-devel
mailing list