diff options
author | wm4 <wm4@nowhere> | 2014-03-31 18:44:44 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-04-17 22:58:46 +0200 |
commit | 8d2baaa31842ed84309ea6810092a02fcb961373 (patch) | |
tree | 01f849a9a04702a26441c876ea716c35faa6a3a9 | |
parent | 2758bc462dea70cea41096dd69b865f1f1f6564e (diff) | |
download | mpv-8d2baaa31842ed84309ea6810092a02fcb961373.tar.bz2 mpv-8d2baaa31842ed84309ea6810092a02fcb961373.tar.xz |
ass_mp: don't use --subcp for --ass-styles
The --ass-styles option is implemented by calling ass_read_styles().
This function can take a codepage (so libass will use iconv to convert
it). This was implemented before our --subcp option was changed, and
this code was not updated. Now libass fails opening iconv, because
--subcp is not always (and not by default) a valid iconv codepage.
Just always pass NULL, which means the file passed to --ass-styles must
be in UTF-8. The --ass-styles option is a fringe option anyway (and will
destroy your subtitles), so having codepage support for it isn't
important at all.
-rw-r--r-- | sub/ass_mp.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sub/ass_mp.c b/sub/ass_mp.c index 422da9dc39..e3b3d39853 100644 --- a/sub/ass_mp.c +++ b/sub/ass_mp.c @@ -83,7 +83,7 @@ void mp_ass_set_style(ASS_Style *style, double res_y, void mp_ass_add_default_styles(ASS_Track *track, struct MPOpts *opts) { if (opts->ass_styles_file && opts->ass_style_override) - ass_read_styles(track, opts->ass_styles_file, opts->sub_cp); + ass_read_styles(track, opts->ass_styles_file, NULL); if (track->n_styles == 0) { if (!track->PlayResY) { |