mirror of https://github.com/mpv-player/mpv
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.
This commit is contained in:
parent
1f7decc1a0
commit
517d6dbfca
|
@ -99,6 +99,7 @@ switch(video_codec){
|
||||||
// in case no strf chunk has been seen in avi, we have no bitmap header
|
// in case no strf chunk has been seen in avi, we have no bitmap header
|
||||||
if(!sh_video->bih) return 0;
|
if(!sh_video->bih) return 0;
|
||||||
sh_video->format=sh_video->bih->biCompression;
|
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_w=sh_video->bih->biWidth;
|
||||||
sh_video->disp_h=abs(sh_video->bih->biHeight);
|
sh_video->disp_h=abs(sh_video->bih->biHeight);
|
||||||
}
|
}
|
||||||
|
@ -392,7 +393,9 @@ mpeg_header_parser:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
} // switch(file_format)
|
} // 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;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue