summaryrefslogtreecommitdiffstats
path: root/sub
diff options
context:
space:
mode:
authorRudolf Polzer <divverent@xonotic.org>2012-12-28 08:38:18 +0100
committerRudolf Polzer <divverent@xonotic.org>2012-12-28 08:40:40 +0100
commit671ca2a570ed030a2d18c63d2090f0571355dc3d (patch)
tree831fca4886c14008055d1ce74ee11a823686c454 /sub
parentc3cc38e4c40d23178330e035c8befc0443a2868b (diff)
downloadmpv-671ca2a570ed030a2d18c63d2090f0571355dc3d.tar.bz2
mpv-671ca2a570ed030a2d18c63d2090f0571355dc3d.tar.xz
demux_mpg, ass_mp: fix warnings
The warnings in demux_mpg were silenced by additional no-operation casts. A variable in ass_mp was used only for some versions of libass; now the declaration is in that version #ifdef too to avoid a compiler warning.
Diffstat (limited to 'sub')
-rw-r--r--sub/ass_mp.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sub/ass_mp.c b/sub/ass_mp.c
index c992f017f7..44f01ac186 100644
--- a/sub/ass_mp.c
+++ b/sub/ass_mp.c
@@ -232,13 +232,17 @@ void mp_ass_configure(ASS_Renderer *priv, struct MPOpts *opts,
ass_set_margins(priv, dim->mt, dim->mb, dim->ml, dim->mr);
int set_use_margins = 0;
+#if LIBASS_VERSION >= 0x01010000
int set_sub_pos = 0;
+#endif
float set_line_spacing = 0;
float set_font_scale = 1;
int set_hinting = 0;
if (opts->ass_style_override) {
set_use_margins = opts->ass_use_margins;
+#if LIBASS_VERSION >= 0x01010000
set_sub_pos = 100 - sub_pos;
+#endif
set_line_spacing = opts->ass_line_spacing;
set_font_scale = opts->sub_scale;
set_hinting = opts->ass_hinting & 3; // +4 was for no hinting if scaled