[vlc-commits] codec: ttml: don't round up font size

Francois Cartegnie git at videolan.org
Sun Dec 24 21:00:39 CET 2017


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Sun Dec 24 20:44:04 2017 +0100| [9890a5578da129321d829741ca5b00a7f875a7ac] | committer: Francois Cartegnie

codec: ttml: don't round up font size

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=9890a5578da129321d829741ca5b00a7f875a7ac
---

 modules/codec/ttml/substtml.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/modules/codec/ttml/substtml.c b/modules/codec/ttml/substtml.c
index 1d5862415c..30a22cc2a5 100644
--- a/modules/codec/ttml/substtml.c
+++ b/modules/codec/ttml/substtml.c
@@ -458,7 +458,7 @@ static void ComputeTTMLStyles( ttml_context_t *p_ctx, const vlc_dictionary_t *p_
         p_text_style->f_font_relsize = len.i_value /
                     (p_ctx->i_cell_resolution_v * TTML_LINE_TO_HEIGHT_RATIO);
     else if( len.unit == TTML_UNIT_PIXELS )
-        p_text_style->i_font_size = (int)( len.i_value + 0.5 );
+        p_text_style->i_font_size = len.i_value;
 }
 
 static void FillTTMLStyle( const char *psz_attr, const char *psz_val,



More information about the vlc-commits mailing list