diff options
author | Dan Oscarsson <DanOscarsson@users.noreply.github.com> | 2017-02-01 13:19:09 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2017-02-01 16:42:58 +0100 |
commit | f1c9032ddf5eba1241d9616656b4c36bc4043283 (patch) | |
tree | 6c7e84dbca6d3631ac4330ed32987eb609deab8c /sub/ass_mp.c | |
parent | bbf01346ff684f0f6a8cc8489b00920956dc16eb (diff) | |
download | mpv-f1c9032ddf5eba1241d9616656b4c36bc4043283.tar.bz2 mpv-f1c9032ddf5eba1241d9616656b4c36bc4043283.tar.xz |
sub: add justify of subtitles
To make it easier for the eyes, multi line subtitles should
be left justified (for most languages).
This adds an option to define how subtitles are to be justified
inpendently of how they are aligned.
Also add option to enable --sub-justify to be applied on ASS subtitles.
Diffstat (limited to 'sub/ass_mp.c')
-rw-r--r-- | sub/ass_mp.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sub/ass_mp.c b/sub/ass_mp.c index 84a706b681..6d85ac1f28 100644 --- a/sub/ass_mp.c +++ b/sub/ass_mp.c @@ -78,6 +78,9 @@ void mp_ass_set_style(ASS_Style *style, double res_y, style->ScaleX = 1.; style->ScaleY = 1.; style->Alignment = 1 + (opts->align_x + 1) + (opts->align_y + 2) % 3 * 4; +#ifdef ASS_JUSTIFY_LEFT + style->Justify = opts->justify; +#endif style->Blur = opts->blur; style->Bold = opts->bold; style->Italic = opts->italic; |