EXA: Fix check for whether the glyph we're evicting from the cache is in use.
Since commit f07f18231a
('EXA: Allow using
exaCompositeRects also when we can't use a mask in exaGlyphs.') we were
checking the wrong set of coordinates in the buffer where glyphs to be rendered
are accumulated when no mask is used in exaGlyphs.
This fixes occasional glyph corruption which can be corrected with redraws, in
particular with Qt4.
Thanks to Maarten Maathuis for asking the right question: 'where do we protect
against evicting glyphs that are still needed?'
Signed-off-by: Michel Dänzer <daenzer@vmware.com>
This commit is contained in:
parent
9d5141f7bc
commit
265d20068a
|
@ -469,7 +469,9 @@ exaGlyphCacheBufferGlyph(ScreenPtr pScreen,
|
|||
y = CACHE_Y(pos);
|
||||
|
||||
for (i = 0; i < buffer->count; i++) {
|
||||
if (buffer->rects[i].xSrc == x && buffer->rects[i].ySrc == y) {
|
||||
if (pSrc ?
|
||||
(buffer->rects[i].xMask == x && buffer->rects[i].yMask == y) :
|
||||
(buffer->rects[i].xSrc == x && buffer->rects[i].ySrc == y)) {
|
||||
DBG_GLYPH_CACHE((" must flush buffer\n"));
|
||||
return ExaGlyphNeedFlush;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue