[Libav-user] mpeg-ts, rtp and output-example
ebersbac at hs-mittweida.de
Tue Dec 6 07:55:46 CET 2011
Am 5.12.2011 23:36, schrieb david.weber at l-3com.com:
> I am attempting to write a mpeg-ts application. Step one would be
> getting an existing application working, so I can dissect the code.
> So, I first took output-example (and the latest release), and modified
> the av_guess_format to:
> fmt = av_guess_format("mpegts", NULL, NULL);
> I also modify the STREAM_DURATION to be very long (500000) or so. I
> know this will be an issue, but I'm trying to get it working.
> I compile and run it, wishing to write to the network, and then read
> it locally using ffplay/vlc.
> [root at sl6 src]# ./output-example rtp://192.168.1.2:9778
> Output #0, mpegts, to 'rtp://192.168.1.2:9778':
> Stream #0.0: Video: mpeg2video, yuv420p, 352x288, q=2-31, 400
> kb/s, 90k tbn, 25 tbc
> Stream #0.1: Audio: mp2, 44100 Hz, 2 channels, s16, 64 kb/s
> [mpegts @ 0x8324020] muxrate VBR, pcr every 2 pkts, sdt every 200,
> pat/pmt every 40 pkts
> I then try VLC, where I play network stream "rtp://192.168.1.2:9778"
> (this is on the same machine as the sender).
> No output. Under messages, it says "rtp warning: too many RTP sessions".
> So, I check wireshark, and when VLC is not running, I am getting icmp
> port not open messages, and those go away when I start VLC.
> Any thoughts? Something not quite set up right in the TS options?
the format mpegts changes are right (fmt = av_guess_format("mpegts",
NULL, NULL);). The problem is, that if you have the format MPEG-TS
libav don't use rtp as output method. Try to open the stream in vlc with
udp://192.168.1.2:9778. To output mpegts with rtp you have to do more
than adapting the output example, look at the mailinglist thread
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Libav-user