]> granicus.if.org Git - libass/commit
Reduce number of glyph copies
authorGrigori Goronzy <greg@blackbox>
Sat, 26 Jun 2010 23:25:56 +0000 (01:25 +0200)
committerGrigori Goronzy <greg@blackbox>
Sat, 26 Jun 2010 23:43:21 +0000 (01:43 +0200)
commit0017fffe84a10a6ed6f7dcdaa1b81ae3bc3a2eb1
treec418e9bd85251537b0639f3802a36582786878ca
parent7aba2042fd6cc1f844bded341f4e8e3db742f2cb
Reduce number of glyph copies

Do not copy glyphs when it isn't really needed.
Profiling with valgrind's callgrind showed that FT_Glyph_Copy takes a
big fraction of the rendering time (~40%) for "simple styled softsubs"
cases. It turned out that glyphs are duplicated much more often than
is necessary. Reducing the number of copies cuts down the rendering
time for the "simple styled softsubs" case by about 70%!
libass/ass_render.c