[FFmpeg-user] problem with converting rtp packets to an audio format

M. V. bored_to_death85 at yahoo.com
Mon Jul 29 22:55:11 CEST 2013


hi guys,

I'm new to ffmpeg. I'm developing a program which receives and recognizes rtp (+sip/sdp) packets from interface and writes rtp content (just rtp part, not udp and ip header) to a file. now I wanna use "ffmpeg"  to convert this file to an audio format. for this I use:
    #ffmpeg -f rtp -i /locaton/of/my/rtp/file output.au
and I receive this error:

-----------------------------------------------------------------------------
[rtp @ 0x2d62880] Guessing on RTP content - if not received properly you need an SDP file describing it
Guessed Channel Layout for  Input Stream #0.0 : mono
Input #0, rtp, from '/location/to/my/rtp/file':
  Duration: N/A, bitrate: 64 kb/s
    Stream #0:0: Audio: pcm_alaw, 8000 Hz, mono, s16, 64 kb/s
Output #0, au, to '/output.au':
  Metadata:
    encoder         : Lavf55.12.100
    Stream #0:0: Audio: pcm_s16be ([3][0][0][0] / 0x0003), 8000 Hz, mono, s16, 128 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_alaw -> pcm_s16be)/location/to/my/rtp/file: Connection timed out
size=       0kB time=-577014:-32:-22.-77 bitrate=N/A    
size=       0kB time=00:00:00.00 bitrate=N/A    
video:0kB audio:0kB subtitle:0 global headers:0kB muxing overhead inf%
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)
-----------------------------------------------------------------------------


so what am I doing wrong?
- should I write the whole rtp packets (with ethernet/ip/udp headers) to file or just rtp-section of packets are enough?
- do I also need to write all related sdp (and sip) packets to a separate file?
- if so, how can I introduce this file to ffmpeg?

I googled a lot and checked documentation, but didn't find an answer. (most of what I found was about playing rtp from ffmpeg)


any help would be much appreciated.

thank you.


More information about the ffmpeg-user mailing list