[MPlayer-dev-eng] Re: Mplayer unable to play MPEG2-TS over RTP (Was: Mplayer as a Client for VideoLAN server)
Rett Walters
rettw at rtwnetwork.com
Sun Jul 20 19:32:05 CEST 2003
Nico (nsabbi at libero.it) wrote:
>
>
>Hi,
>
>attached is a prototype of a patch that (if my understanding of
>mplayer's demuxing api is correct) should solve Rett's problem.
>
>I believe it's general and clean enough to prevent misdetetctions of
>streams.
>Especially consider these two lines:
>
>+ od = demux_open_stream(s, DEMUXER_TYPE_UNKNOWN, -1, -1, -1, NULL);
>+ // WILL TURN TO (OR CAN BE FORCED TO) DEMUXER_TYPE_MPEG_TS or any
other DEMUXER_TYPE_* if needed of correctly flagged
>+
>
>It implements the pipelined demuxing that I adviced in a previous email.
>
>Note that the resulting demuxer deals only with streams that have audio
>and video interleaved in one,
>but changing it so as to deal with seperate streams is trivial: just
>reassign sh_audio if an audio demuxer_stream was previously open.
>
>I'm not totally sure it's the best/cleanest way to create a pipelined
>demuxing, but as far as I can see (and considering the total lack of docs,
>and that the only reference I had was a mail by Arpi (thanks!) ) it
>seems correct (some warnings apart).
>
>I tested it streaming via VLS a TS file to 127.0.0.1 and using
>
>./mplayer sdp:///root/file.sdp
>
>where file.sdp contains
>
>v=0
>s=Test MPEG-2 TS session
>t=0 0
>m=video 1234 RTP/AVP 33
>c=IN IP4 127.0.0.1/255
>
>
Well, we are definately closer!
Thanks for the patch - I applied it and found that it works - except for the issue
you pointed out with the demuxer code for ts. What I get is about 10 secs of good
video and audio before I get start to get video corruption and eventually a bunch of
messages like this:
A: 0.0 V: 386.9 A-V:-386.928 ct: -0.972 240/237 28% 10% 20.5% 1 0 0%
Too many video packets in the buffer: (4096 in 691040 bytes).
Maybe you are playing a non-interleaved stream/file or the codec failed?
For AVI files, try to force non-interleaved mode with the -ni option.
A: 0.0 V: 386.9 A-V:-386.928 ct: -0.972 240/237 28% 10% 20.5% 1 0 0%
Too many video packets in the buffer: (4096 in 691040 bytes).
Maybe you are playing a non-interleaved stream/file or the codec failed?
For AVI files, try to force non-interleaved mode with the -ni option.
I am using a similiar sdp file, except that I am sending the stream across my
network using a multicast.
I am also streaming a DVD instead of a single file with VLS - here is my VLS ommand:
vls -vvv -d rtp:234.5.6.7:1234 dvd:/dev/dvd --ttl 1>
You might want to look at the VideoLAN project's videolan client for info on how
their demuxer deals with a TS stream at high bit rates. Xine also has an MPEG2 TS
demuxer that works very well with this application.
Thanks again!
Rett Walters
More information about the MPlayer-dev-eng
mailing list