diff options
author | marha <marha@users.sourceforge.net> | 2009-12-02 19:35:37 +0000 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2009-12-02 19:35:37 +0000 |
commit | 8f2c5e2f41f211bed814be2889da16fc43e6f147 (patch) | |
tree | e1f2715f63544d39302d6daa2cb0d4f53d295ebc /xorg-server/exa/exa_classic.c | |
parent | b404fe88bb87f42267cab4682b81f38cc442e617 (diff) | |
parent | 314d225f3a60cc0ea63c292a2c2ffe3609e7c739 (diff) | |
download | vcxsrv-8f2c5e2f41f211bed814be2889da16fc43e6f147.tar.gz vcxsrv-8f2c5e2f41f211bed814be2889da16fc43e6f147.tar.bz2 vcxsrv-8f2c5e2f41f211bed814be2889da16fc43e6f147.zip |
svn merge ^/branches/released
Diffstat (limited to 'xorg-server/exa/exa_classic.c')
-rw-r--r-- | xorg-server/exa/exa_classic.c | 22 |
1 files changed, 15 insertions, 7 deletions
diff --git a/xorg-server/exa/exa_classic.c b/xorg-server/exa/exa_classic.c index 1eff57091..c31e2d4b3 100644 --- a/xorg-server/exa/exa_classic.c +++ b/xorg-server/exa/exa_classic.c @@ -38,7 +38,7 @@ ExaGetPixmapAddress(PixmapPtr p) { ExaPixmapPriv(p); - if (pExaPixmap->offscreen && pExaPixmap->fb_ptr) + if (pExaPixmap->use_gpu_copy && pExaPixmap->fb_ptr) return pExaPixmap->fb_ptr; else return pExaPixmap->sys_ptr; @@ -90,7 +90,7 @@ exaCreatePixmap_classic(ScreenPtr pScreen, int w, int h, int depth, pExaPixmap->sys_pitch = pPixmap->devKind; pPixmap->devPrivate.ptr = NULL; - pExaPixmap->offscreen = FALSE; + pExaPixmap->use_gpu_copy = FALSE; pExaPixmap->fb_ptr = NULL; exaSetFbPitch(pExaScr, pExaPixmap, w, h, bpp); @@ -137,6 +137,10 @@ exaCreatePixmap_classic(ScreenPtr pScreen, int w, int h, int depth, exaSetAccelBlock(pExaScr, pExaPixmap, w, h, bpp); + /* During a fallback we must prepare access. */ + if (pExaScr->fallback_counter) + exaPrepareAccess(&pPixmap->drawable, EXA_PREPARE_AUX_DEST); + return pPixmap; } @@ -164,7 +168,7 @@ exaModifyPixmapHeader_classic(PixmapPtr pPixmap, int width, int height, int dept /* Classic EXA: * - Framebuffer. - * - Scratch pixmap with offscreen memory. + * - Scratch pixmap with gpu memory. */ if (pExaScr->info->memoryBase && pPixData) { if ((CARD8 *)pPixData >= pExaScr->info->memoryBase && @@ -172,7 +176,7 @@ exaModifyPixmapHeader_classic(PixmapPtr pPixmap, int width, int height, int dept pExaScr->info->memorySize) { pExaPixmap->fb_ptr = pPixData; pExaPixmap->fb_pitch = devKind; - pExaPixmap->offscreen = TRUE; + pExaPixmap->use_gpu_copy = TRUE; } } @@ -185,7 +189,7 @@ exaModifyPixmapHeader_classic(PixmapPtr pPixmap, int width, int height, int dept } /* Pixmaps subject to ModifyPixmapHeader will be pinned to system or - * offscreen memory, so there's no need to track damage. + * gpu memory, so there's no need to track damage. */ if (pExaPixmap->pDamage) { DamageUnregister(&pPixmap->drawable, pExaPixmap->pDamage); @@ -216,6 +220,10 @@ exaDestroyPixmap_classic (PixmapPtr pPixmap) { ExaPixmapPriv (pPixmap); + /* During a fallback we must finish access, but we don't know the index. */ + if (pExaScr->fallback_counter) + exaFinishAccess(&pPixmap->drawable, -1); + if (pExaPixmap->area) { DBG_PIXMAP(("-- 0x%p (0x%x) (%dx%d)\n", @@ -240,7 +248,7 @@ exaDestroyPixmap_classic (PixmapPtr pPixmap) } Bool -exaPixmapIsOffscreen_classic(PixmapPtr pPixmap) +exaPixmapHasGpuCopy_classic(PixmapPtr pPixmap) { ScreenPtr pScreen = pPixmap->drawable.pScreen; ExaScreenPriv(pScreen); @@ -252,7 +260,7 @@ exaPixmapIsOffscreen_classic(PixmapPtr pPixmap) ret = pExaScr->info->PixmapIsOffscreen(pPixmap); pPixmap->devPrivate.ptr = NULL; } else - ret = (pExaPixmap->offscreen && pExaPixmap->fb_ptr); + ret = (pExaPixmap->use_gpu_copy && pExaPixmap->fb_ptr); return ret; } |