summaryrefslogtreecommitdiffstats
path: root/demux
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-02-11 07:57:47 +0100
committerwm4 <wm4@nowhere>2013-02-12 10:16:38 +0100
commit517d6dbfca9e2d111e3d4fe1a9f5f6a7e1f58b54 (patch)
tree0676d6ddbb26f09dd8dd6b1436fb1a7a736eceda /demux
parent1f7decc1a0a7e0f2fb547ee740ee0d7b659c0406 (diff)
downloadmpv-517d6dbfca9e2d111e3d4fe1a9f5f6a7e1f58b54.tar.bz2
mpv-517d6dbfca9e2d111e3d4fe1a9f5f6a7e1f58b54.tar.xz
demux: fix video with demux_mpg (DVD playback)
Commit 4d016a9 changed how demuxers report the codec of each stream. Some of that was missed in video.c, which is important for legacy demuxers (demux_mpg was broken by this, which is needed for DVD playback). Not sure about the ASF/AVI related change, but this is also a legacy demuxers only codepath.
Diffstat (limited to 'demux')
-rw-r--r--demux/video.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/demux/video.c b/demux/video.c
index 02ecf9d4a7..ed40bfde30 100644
--- a/demux/video.c
+++ b/demux/video.c
@@ -99,6 +99,7 @@ switch(video_codec){
// in case no strf chunk has been seen in avi, we have no bitmap header
if(!sh_video->bih) return 0;
sh_video->format=sh_video->bih->biCompression;
+ mp_set_video_codec_from_tag(sh_video);
sh_video->disp_w=sh_video->bih->biWidth;
sh_video->disp_h=abs(sh_video->bih->biHeight);
}
@@ -392,7 +393,9 @@ mpeg_header_parser:
break;
}
} // switch(file_format)
-
+if (d_video->demuxer->file_format == DEMUXER_TYPE_MPEG_PS ||
+ d_video->demuxer->file_format == DEMUXER_TYPE_MPEG_TS)
+ mp_set_video_codec_from_tag(sh_video);
return 1;
}