summaryrefslogtreecommitdiffstats
path: root/sub/dec_sub.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-02-13 22:54:15 +0100
committerwm4 <wm4@nowhere>2014-03-11 00:08:29 +0100
commite4c69376fc13c21a8ecb09a45d01045f88f40b58 (patch)
tree2d8884b923aa92c09a672f13a7c0731f1109ca59 /sub/dec_sub.c
parent842689bbf632218eacfd84dfab2b83d6954bdc93 (diff)
downloadmpv-e4c69376fc13c21a8ecb09a45d01045f88f40b58.tar.bz2
mpv-e4c69376fc13c21a8ecb09a45d01045f88f40b58.tar.xz
sub: handle vobsub-in-mp4
The mplayer decoder (spudec.c) actually handled this. There was explicit code for binary palettes (16 32 bit values), and the subtitle resolution was handled by video resolution coincidentally matching the subtitle resolution. Whoever puts vobsub into mp4 should be punished. Fixes the sample gundam_sample.mp4, closes github issue #547.
Diffstat (limited to 'sub/dec_sub.c')
-rw-r--r--sub/dec_sub.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sub/dec_sub.c b/sub/dec_sub.c
index 102a048da3..1b364ee4f4 100644
--- a/sub/dec_sub.c
+++ b/sub/dec_sub.c
@@ -175,6 +175,8 @@ void sub_init_from_sh(struct dec_sub *sub, struct sh_stream *sh)
struct sd init_sd = sub->init_sd;
init_sd.codec = sh->codec;
init_sd.ass_track = sh->sub->track;
+ init_sd.sub_stream_w = sh->sub->w;
+ init_sd.sub_stream_h = sh->sub->h;
while (sub->num_sd < MAX_NUM_SD) {
struct sd *sd = talloc(NULL, struct sd);