mirror of https://github.com/mpv-player/mpv
parse_es init fixed
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@1659 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
e25be3b9fa
commit
aa7414a685
|
@ -591,6 +591,7 @@ switch(d_video->demuxer->file_format){
|
|||
case DEMUXER_TYPE_MPEG_ES:
|
||||
case DEMUXER_TYPE_MPEG_PS: {
|
||||
// Find sequence_header first:
|
||||
videobuf_len=0; videobuf_code_len=0;
|
||||
mp_msg(MSGT_DECVIDEO,MSGL_V,"Searching for sequence header... ");fflush(stdout);
|
||||
while(1){
|
||||
int i=sync_video_packet(d_video);
|
||||
|
@ -606,13 +607,13 @@ switch(d_video->demuxer->file_format){
|
|||
// sh_video=d_video->sh;sh_video->ds=d_video;
|
||||
mpeg2_init();
|
||||
// ========= Read & process sequence header & extension ============
|
||||
videobuffer=memalign(8,VIDEOBUFFER_SIZE);
|
||||
if(!videobuffer) videobuffer=memalign(8,VIDEOBUFFER_SIZE);
|
||||
if(!videobuffer){
|
||||
mp_msg(MSGT_DECVIDEO,MSGL_ERR,"Cannot allocate shared memory\n");
|
||||
return 0;
|
||||
// GUI_MSG( mplErrorShMemAlloc )
|
||||
}
|
||||
videobuf_len=0;
|
||||
|
||||
if(!read_video_packet(d_video)){
|
||||
mp_msg(MSGT_DECVIDEO,MSGL_ERR,"FATAL: Cannot read sequence header!\n");
|
||||
return 0;
|
||||
|
|
Loading…
Reference in New Issue