Mercurial > mplayer.hg
comparison libmpdemux/demux_ts.c @ 18714:8fc996a3b4e1
reduced standard verbosity and changed output messages to more uniform descriptions
author | nicodvb |
---|---|
date | Wed, 14 Jun 2006 22:22:34 +0000 |
parents | a109f55ad8d8 |
children | 45e1650f9ad5 |
comparison
equal
deleted
inserted
replaced
18713:c6c78e77c857 | 18714:8fc996a3b4e1 |
---|---|
571 req_spid = param->spid; | 571 req_spid = param->spid; |
572 | 572 |
573 has_tables = 0; | 573 has_tables = 0; |
574 memset(pes_priv1, 0, sizeof(pes_priv1)); | 574 memset(pes_priv1, 0, sizeof(pes_priv1)); |
575 init_pos = stream_tell(demuxer->stream); | 575 init_pos = stream_tell(demuxer->stream); |
576 mp_msg(MSGT_DEMUXER, MSGL_INFO, "PROBING UP TO %"PRIu64", PROG: %d\n", (uint64_t) param->probe, param->prog); | 576 mp_msg(MSGT_DEMUXER, MSGL_V, "PROBING UP TO %"PRIu64", PROG: %d\n", (uint64_t) param->probe, param->prog); |
577 while((pos <= init_pos + param->probe) && (! demuxer->stream->eof)) | 577 while((pos <= init_pos + param->probe) && (! demuxer->stream->eof)) |
578 { | 578 { |
579 pos = stream_tell(demuxer->stream); | 579 pos = stream_tell(demuxer->stream); |
580 if(ts_parse(demuxer, &es, tmp, 1)) | 580 if(ts_parse(demuxer, &es, tmp, 1)) |
581 { | 581 { |
610 if((! is_audio) && (! is_video) && (! is_sub)) | 610 if((! is_audio) && (! is_video) && (! is_sub)) |
611 continue; | 611 continue; |
612 | 612 |
613 if(is_video) | 613 if(is_video) |
614 { | 614 { |
615 mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_VIDEO_ID=%d\n", es.pid); | 615 mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_VIDEO_ID=%d\n", es.pid); |
616 chosen_pid = (req_vpid == es.pid); | 616 chosen_pid = (req_vpid == es.pid); |
617 if((! chosen_pid) && (req_vpid > 0)) | 617 if((! chosen_pid) && (req_vpid > 0)) |
618 continue; | 618 continue; |
619 } | 619 } |
620 else if(is_audio) | 620 else if(is_audio) |
621 { | 621 { |
622 mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_AUDIO_ID=%d\n", es.pid); | 622 mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_AUDIO_ID=%d\n", es.pid); |
623 if (es.lang[0] > 0) | 623 if (es.lang[0] > 0) |
624 mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_AID_%d_LANG=%s\n", es.pid, es.lang); | 624 mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_AID_%d_LANG=%s\n", es.pid, es.lang); |
625 if(req_apid > 0) | 625 if(req_apid > 0) |
626 { | 626 { |
627 chosen_pid = (req_apid == es.pid); | 627 chosen_pid = (req_apid == es.pid); |
628 if(! chosen_pid) | 628 if(! chosen_pid) |
629 continue; | 629 continue; |
637 param->apid = req_apid = es.pid; | 637 param->apid = req_apid = es.pid; |
638 } | 638 } |
639 } | 639 } |
640 else if(is_sub) | 640 else if(is_sub) |
641 { | 641 { |
642 mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SUBTITLE_ID=%d\n", es.pid); | 642 mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_SUBTITLE_ID=%d\n", es.pid); |
643 if (es.lang[0] > 0) | 643 if (es.lang[0] > 0) |
644 mp_msg(MSGT_IDENTIFY, MSGL_INFO, "ID_SID_%d_LANG=%s\n", es.pid, es.lang); | 644 mp_msg(MSGT_IDENTIFY, MSGL_V, "ID_SID_%d_LANG=%s\n", es.pid, es.lang); |
645 chosen_pid = (req_spid == es.pid); | 645 chosen_pid = (req_spid == es.pid); |
646 if((! chosen_pid) && (req_spid > 0)) | 646 if((! chosen_pid) && (req_spid > 0)) |
647 continue; | 647 continue; |
648 } | 648 } |
649 | 649 |
760 } | 760 } |
761 | 761 |
762 if(video_found) | 762 if(video_found) |
763 { | 763 { |
764 if(param->vtype == VIDEO_MPEG1) | 764 if(param->vtype == VIDEO_MPEG1) |
765 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG1(pid=%d)", param->vpid); | 765 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG1(pid=%d) ", param->vpid); |
766 else if(param->vtype == VIDEO_MPEG2) | 766 else if(param->vtype == VIDEO_MPEG2) |
767 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG2(pid=%d)", param->vpid); | 767 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG2(pid=%d) ", param->vpid); |
768 else if(param->vtype == VIDEO_MPEG4) | 768 else if(param->vtype == VIDEO_MPEG4) |
769 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG4(pid=%d)...", param->vpid); | 769 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO MPEG4(pid=%d) ", param->vpid); |
770 else if(param->vtype == VIDEO_H264) | 770 else if(param->vtype == VIDEO_H264) |
771 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO H264(pid=%d)...", param->vpid); | 771 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO H264(pid=%d) ", param->vpid); |
772 else if(param->vtype == VIDEO_AVC) | 772 else if(param->vtype == VIDEO_AVC) |
773 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO AVC(NAL-H264, pid=%d)...", param->vpid); | 773 mp_msg(MSGT_DEMUXER, MSGL_INFO, "VIDEO AVC(NAL-H264, pid=%d) ", param->vpid); |
774 } | 774 } |
775 else | 775 else |
776 { | 776 { |
777 param->vtype = UNKNOWN; | 777 param->vtype = UNKNOWN; |
778 //WE DIDN'T MATCH ANY VIDEO STREAM | 778 //WE DIDN'T MATCH ANY VIDEO STREAM |
860 sh_audio_t *sh_audio; | 860 sh_audio_t *sh_audio; |
861 off_t start_pos; | 861 off_t start_pos; |
862 tsdemux_init_t params; | 862 tsdemux_init_t params; |
863 ts_priv_t * priv = (ts_priv_t*) demuxer->priv; | 863 ts_priv_t * priv = (ts_priv_t*) demuxer->priv; |
864 | 864 |
865 mp_msg(MSGT_DEMUX, MSGL_INFO, "DEMUX OPEN, AUDIO_ID: %d, VIDEO_ID: %d, SUBTITLE_ID: %d,\n", | 865 mp_msg(MSGT_DEMUX, MSGL_V, "DEMUX OPEN, AUDIO_ID: %d, VIDEO_ID: %d, SUBTITLE_ID: %d,\n", |
866 demuxer->audio->id, demuxer->video->id, demuxer->sub->id); | 866 demuxer->audio->id, demuxer->video->id, demuxer->sub->id); |
867 | 867 |
868 | 868 |
869 demuxer->type= DEMUXER_TYPE_MPEG_TS; | 869 demuxer->type= DEMUXER_TYPE_MPEG_TS; |
870 | 870 |
982 memcpy(sh_audio->wf + 1, es->extradata, es->extradata_len); | 982 memcpy(sh_audio->wf + 1, es->extradata, es->extradata_len); |
983 } | 983 } |
984 } | 984 } |
985 | 985 |
986 | 986 |
987 mp_msg(MSGT_DEMUXER,MSGL_INFO, "Opened TS demuxer, audio: %x(pid %d), video: %x(pid %d)...POS=%"PRIu64", PROBE=%"PRIu64"\n", params.atype, demuxer->audio->id, params.vtype, demuxer->video->id, (uint64_t) start_pos, ts_probe); | 987 mp_msg(MSGT_DEMUXER,MSGL_V, "Opened TS demuxer, audio: %x(pid %d), video: %x(pid %d)...POS=%"PRIu64", PROBE=%"PRIu64"\n", params.atype, demuxer->audio->id, params.vtype, demuxer->video->id, (uint64_t) start_pos, ts_probe); |
988 | 988 |
989 | 989 |
990 start_pos = (start_pos <= priv->ts.packet_size ? 0 : start_pos - priv->ts.packet_size); | 990 start_pos = (start_pos <= priv->ts.packet_size ? 0 : start_pos - priv->ts.packet_size); |
991 demuxer->movi_start = start_pos; | 991 demuxer->movi_start = start_pos; |
992 stream_reset(demuxer->stream); | 992 stream_reset(demuxer->stream); |