summaryrefslogtreecommitdiffstats
path: root/libass
diff options
context:
space:
mode:
authorDr.Smile <vabnick@gmail.com>2019-05-20 01:04:22 +0300
committerDr.Smile <vabnick@gmail.com>2019-05-20 01:04:22 +0300
commit20a26e98c27387004151ce291c1e5e0bda3cc0dd (patch)
tree0c0955bebf6bc3445554cc6a6f51740cd1faa998 /libass
parentb475645e31f6d993a4996ec160ee98798b9239e6 (diff)
downloadlibass-20a26e98c27387004151ce291c1e5e0bda3cc0dd.tar.bz2
libass-20a26e98c27387004151ce291c1e5e0bda3cc0dd.tar.xz
renderer: correctly handle case of small but nonzero \bord
Fixes https://github.com/libass/libass/pull/309.
Diffstat (limited to 'libass')
-rw-r--r--libass/ass_render.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libass/ass_render.c b/libass/ass_render.c
index 14aa470..0a2a279 100644
--- a/libass/ass_render.c
+++ b/libass/ass_render.c
@@ -1418,8 +1418,11 @@ get_bitmap_glyph(ASS_Renderer *render_priv, GlyphInfo *info,
frexp(w * (FFMAX(mxy, myy) + mzy * rz), &k->scale_ord_y);
k->border.x = lrint(ldexp(bord_x, k->scale_ord_x) / STROKER_PRECISION);
k->border.y = lrint(ldexp(bord_y, k->scale_ord_y) / STROKER_PRECISION);
- if (!k->border.x && !k->border.y)
+ if (!k->border.x && !k->border.y) {
+ ass_cache_inc_ref(info->bm);
+ info->bm_o = info->bm;
return;
+ }
for (int i = 0; i < 3; i++) {
m[i][0] = ldexp(m2[i][0], -k->scale_ord_x);