xfree86/xv: Remove clipOrg from XvPortRecPrivate
clipOrg never changes except when clientClip changes, so instead of keeping copies of both originals translate clientClip by clipOrg immediately and just keep the translated clientClip. Signed-off-by: Ville Syrjälä <ville.syrjala@nokia.com> Reviewed-by: Luc Verhaegen <luc.verhaegen@basyskom.de>
This commit is contained in:
parent
47d8bd0a99
commit
7294236bdb
|
@ -661,8 +661,7 @@ xf86XVUpdateCompositeClip(XvPortRecPrivatePtr portPriv)
|
|||
pCompositeClip = RegionCreate(NullBox, 1);
|
||||
RegionCopy(pCompositeClip, portPriv->clientClip);
|
||||
RegionTranslate(pCompositeClip,
|
||||
portPriv->pDraw->x + portPriv->clipOrg.x,
|
||||
portPriv->pDraw->y + portPriv->clipOrg.y);
|
||||
portPriv->pDraw->x, portPriv->pDraw->y);
|
||||
RegionIntersect(pCompositeClip, pregWin, pCompositeClip);
|
||||
|
||||
portPriv->pCompositeClip = pCompositeClip;
|
||||
|
@ -687,6 +686,8 @@ xf86XVCopyClip(
|
|||
portPriv->clientClip = RegionCreate(NullBox, 1);
|
||||
/* Note: this is in window coordinates */
|
||||
RegionCopy(portPriv->clientClip, pGC->clientClip);
|
||||
RegionTranslate(portPriv->clientClip,
|
||||
pGC->clipOrg.x, pGC->clipOrg.y);
|
||||
} else if(portPriv->clientClip) { /* free the old clientClip */
|
||||
RegionDestroy(portPriv->clientClip);
|
||||
portPriv->clientClip = NULL;
|
||||
|
@ -697,7 +698,6 @@ xf86XVCopyClip(
|
|||
RegionDestroy(portPriv->pCompositeClip);
|
||||
}
|
||||
|
||||
portPriv->clipOrg = pGC->clipOrg;
|
||||
portPriv->pCompositeClip = pGC->pCompositeClip;
|
||||
portPriv->FreeCompositeClip = FALSE;
|
||||
portPriv->subWindowMode = pGC->subWindowMode;
|
||||
|
|
|
@ -67,7 +67,6 @@ typedef struct {
|
|||
DrawablePtr pDraw;
|
||||
unsigned char type;
|
||||
unsigned int subWindowMode;
|
||||
DDXPointRec clipOrg;
|
||||
RegionPtr clientClip;
|
||||
RegionPtr pCompositeClip;
|
||||
Bool FreeCompositeClip;
|
||||
|
|
Loading…
Reference in New Issue
Block a user