summaryrefslogtreecommitdiff
path: root/exa
diff options
context:
space:
mode:
authorMichel Dänzer <michel@tungstengraphics.com>2008-08-19 11:22:40 +0200
committerMichel Dänzer <michel@tungstengraphics.com>2008-08-19 11:22:40 +0200
commit825b3fe11d1b813bf8d5b24a880ed04b78ae1acf (patch)
tree9aa258f4230d7aa6dad7ea1a83e1384a501175b2 /exa
parent75e495a4cd823b6fa42a8d167ecc9f4723320dea (diff)
EXA: Don't use exaGlyphs if the driver doesn't provide a PrepareComposite hook.
It's buggy without Composite acceleration (leading to cropped glyphs) and not really useful in that case anyway. The bug probably still needs to be found and fixed for drivers that provide a PrepareComposite hook but can't accelerate text rendering though.
Diffstat (limited to 'exa')
-rw-r--r--exa/exa.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/exa/exa.c b/exa/exa.c
index e1bbb3238..37a0bb055 100644
--- a/exa/exa.c
+++ b/exa/exa.c
@@ -752,7 +752,8 @@ exaCloseScreen(int i, ScreenPtr pScreen)
PictureScreenPtr ps = GetPictureScreenIfSet(pScreen);
#endif
- exaGlyphsFini(pScreen);
+ if (ps->Glyphs == exaGlyphs)
+ exaGlyphsFini(pScreen);
pScreen->CreateGC = pExaScr->SavedCreateGC;
pScreen->CloseScreen = pExaScr->SavedCloseScreen;
@@ -931,8 +932,10 @@ exaDriverInit (ScreenPtr pScreen,
pExaScr->SavedComposite = ps->Composite;
ps->Composite = exaComposite;
- pExaScr->SavedGlyphs = ps->Glyphs;
- ps->Glyphs = exaGlyphs;
+ if (pScreenInfo->PrepareComposite) {
+ pExaScr->SavedGlyphs = ps->Glyphs;
+ ps->Glyphs = exaGlyphs;
+ }
pExaScr->SavedTriangles = ps->Triangles;
ps->Triangles = exaTriangles;
@@ -993,7 +996,8 @@ exaDriverInit (ScreenPtr pScreen,
}
}
- exaGlyphsInit(pScreen);
+ if (ps->Glyphs == exaGlyphs)
+ exaGlyphsInit(pScreen);
LogMessage(X_INFO, "EXA(%d): Driver registered support for the following"
" operations:\n", pScreen->myNum);