mirror of
https://github.com/X11Libre/xserver.git
synced 2026-09-27 21:22:26 +00:00
EXA: RENDER improvements.
Exclude bits that will be overwritten from migration. Use exaGlyphs even when Composite can't be accelerated, to avoid PolyFillRect roundtrip via offscreen memory. Initialize mask pixmap in exaGlyphs in FB in addition to system if the driver provides Composite hooks to avoid migration overhead. Remove manual damage tracking where superfluous.
This commit is contained in:
parent
1f457ff3db
commit
a634c9b034
4 changed files with 80 additions and 87 deletions
|
|
@ -23,6 +23,10 @@
|
|||
|
||||
#include "exa_priv.h"
|
||||
|
||||
#ifdef RENDER
|
||||
#include "mipict.h"
|
||||
#endif
|
||||
|
||||
/*
|
||||
* These functions wrap the low-level fb rendering functions and
|
||||
* synchronize framebuffer/accelerated drawing by stalling until
|
||||
|
|
@ -319,9 +323,30 @@ ExaCheckComposite (CARD8 op,
|
|||
CARD16 width,
|
||||
CARD16 height)
|
||||
{
|
||||
RegionRec region;
|
||||
int xoff, yoff;
|
||||
|
||||
REGION_NULL(pScreen, ®ion);
|
||||
|
||||
if (!exaOpReadsDestination(op)) {
|
||||
if (!miComputeCompositeRegion (®ion, pSrc, pMask, pDst,
|
||||
xSrc, ySrc, xMask, yMask, xDst, yDst,
|
||||
width, height))
|
||||
return;
|
||||
|
||||
exaGetDrawableDeltas (pDst->pDrawable,
|
||||
exaGetDrawablePixmap(pDst->pDrawable),
|
||||
&xoff, &yoff);
|
||||
|
||||
REGION_TRANSLATE(pScreen, ®ion, xoff, yoff);
|
||||
|
||||
exaPrepareAccessReg (pDst->pDrawable, EXA_PREPARE_DEST, ®ion);
|
||||
} else
|
||||
exaPrepareAccess (pDst->pDrawable, EXA_PREPARE_DEST);
|
||||
|
||||
EXA_FALLBACK(("from picts %p/%p to pict %p\n",
|
||||
pSrc, pMask, pDst));
|
||||
exaPrepareAccess (pDst->pDrawable, EXA_PREPARE_DEST);
|
||||
|
||||
if (pSrc->pDrawable != NULL)
|
||||
exaPrepareAccess (pSrc->pDrawable, EXA_PREPARE_SRC);
|
||||
if (pMask && pMask->pDrawable != NULL)
|
||||
|
|
@ -343,6 +368,8 @@ ExaCheckComposite (CARD8 op,
|
|||
if (pSrc->pDrawable != NULL)
|
||||
exaFinishAccess (pSrc->pDrawable, EXA_PREPARE_SRC);
|
||||
exaFinishAccess (pDst->pDrawable, EXA_PREPARE_DEST);
|
||||
|
||||
REGION_UNINIT(pScreen, ®ion);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue