From b9809c1e13c59fec291ca9fd20911808acb5b154 Mon Sep 17 00:00:00 2001 From: eugeni Date: Fri, 20 Apr 2007 23:11:39 +0000 Subject: 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. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23041 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libass/ass_render.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libass/ass_render.c b/libass/ass_render.c index eafcd9668e..486b58ea14 100644 --- a/libass/ass_render.c +++ b/libass/ass_render.c @@ -393,7 +393,7 @@ static ass_image_t* render_text(text_info_t* text_info, int dst_x, int dst_y) 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 @@ static int ass_render_event(ass_event_t* event, event_images_t* event_images) 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); + } } } -- cgit v1.2.3