I want to receive a RTP Stream and send the raw data received in it over TCP / UDP socket. For this i am trying following commands.
I am sending the RTP stream using following command.
ffmpeg -re -i hello.wav -ar 8000 -f mulaw -f rtp rtp://127.0.0.1:1234
Receiver to re transmit the stream over TCP / UDP socket.
ffmpeg -i rtp://127.0.0.1:1234 -f mulaw tcp://127.0.0.1:5555 -hide_banner
A Player to play this Socket stream to verify.
ffplay tcp://127.0.0.1:5555?listen
My second command shows that its receiving data and transmitting the data to tcp over 5555 port.
Input #0, rtp, from 'rtp://127.0.0.1:1234':
Duration: N/A, start: 0.000000, bitrate: 64 kb/s
Stream #0:0: Audio: pcm_mulaw, 8000 Hz, mono, s16, 64 kb/s
Stream mapping:
Stream #0:0 -> #0:0 (pcm_mulaw (native) -> pcm_mulaw (native))
Press [q] to stop, [?] for help
Output #0, mulaw, to 'tcp://127.0.0.1:5555':
Metadata:
encoder : Lavf58.29.100
Stream #0:0: Audio: pcm_mulaw, 8000 Hz, mono, s16, 64 kb/s
Metadata:
encoder : Lavc58.54.100 pcm_mulaw
But the third command does not receive anything, even i tried dumping the response into a file using FFMPEG in command three but same results.
What am i doing wrong, Please suggest the correct commands using FFMPEG.