# HG changeset patch # User eugeni # Date 1177110699 0 # Node ID 0694bbf7ac84b954c9043c4ca90e459afc23aeac # Parent 199a3c6f54e87dbb6608c41fa79bfe703504c25e Because of the outline glyph cache it is now possible for glyph_info_t to have both non-zero glyph and bitmap at the same time. In that case, bitmap should not be generated anew. diff -r 199a3c6f54e8 -r 0694bbf7ac84 libass/ass_render.c --- a/libass/ass_render.c Fri Apr 20 23:10:33 2007 +0000 +++ b/libass/ass_render.c Fri Apr 20 23:11:39 2007 +0000 @@ -393,7 +393,7 @@ ass_image_t** tail = &head; for (i = 0; i < text_info->length; ++i) { - if (text_info->glyphs[i].glyph) { + if (text_info->glyphs[i].glyph && text_info->glyphs[i].bm == 0) { if ((text_info->glyphs[i].symbol == '\n') || (text_info->glyphs[i].symbol == 0)) continue; error = glyph_to_bitmap(ass_renderer->synth_priv, @@ -1950,11 +1950,13 @@ FT_Vector shift; glyph_info_t* info = text_info.glyphs + i; + if (info->bm == 0) { // calculating shift vector shift.x = int_to_d6(info->pos.x + device_x - center.x); shift.y = - int_to_d6(info->pos.y + device_y - center.y); transform_3d(shift, &info->glyph, &info->outline_glyph, info->frx, info->fry, info->frz); + } } }