summaryrefslogtreecommitdiffstats
path: root/mplayer.c
diff options
context:
space:
mode:
authorUoti Urpala <uau@glyph.nonexistent.invalid>2010-05-19 01:05:25 +0300
committerUoti Urpala <uau@glyph.nonexistent.invalid>2011-01-18 15:17:28 +0200
commit4284cf9ef050044619c773b195f0eb941f922e88 (patch)
treefa1c57bce88ca589a4dc00390dc35860fb928a16 /mplayer.c
parentd5eaf6a820d73181f07de3387cd1c115a49648f5 (diff)
downloadmpv-4284cf9ef050044619c773b195f0eb941f922e88.tar.bz2
mpv-4284cf9ef050044619c773b195f0eb941f922e88.tar.xz
subtitles: style support for common SubRip tags and MicroDVD
SubRip subtitles have no "official" spec for any styling support, but various tags are in common use; previous code filtered out text between <> to remove HTML-style tags. Add support for those tags and for MicroDVD subtitle styling. The style display is implemented by converting the subtitles to the ASS subtitle format and displaying them with libass, so libass needs to be enabled. Original patch by Clément Bœsch <ubitux@gmail.com>.
Diffstat (limited to 'mplayer.c')
-rw-r--r--mplayer.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mplayer.c b/mplayer.c
index 69e4dcd0fb..1c41e35f9d 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -1105,7 +1105,7 @@ void add_subtitles(struct MPContext *mpctx, char *filename, float fps, int noerr
asst = ass_read_stream(ass_library, filename, 0);
#endif
if (!asst) {
- subd = sub_read_file(filename, fps);
+ subd = sub_read_file(filename, fps, &mpctx->opts);
if (subd) {
asst = ass_read_subdata(ass_library, subd, fps);
if (asst) {
@@ -1116,7 +1116,7 @@ void add_subtitles(struct MPContext *mpctx, char *filename, float fps, int noerr
}
} else
#endif
- subd = sub_read_file(filename, fps);
+ subd = sub_read_file(filename, fps, &mpctx->opts);
if (!asst && !subd) {