Receive multicast RTP

Need help with MPD?
Post Reply
skidoo
Posts: 154
Joined: April 28th, 2013, 10:06 pm
Location: Western Germany

Receive multicast RTP

Post by skidoo » February 11th, 2016, 3:26 pm

MPD together with ffmpeg is able to produce a multcast RTP stream.

mpd.conf

Code: Select all

audio_output {
 type "pipe"
 name "Multicast RTP"
 command "ffmpeg -nostats -re -f s16le -ac 2 -i pipe:0 -acodec pcm_s16be -f rtp rtp://239.9.3.2:5004"
 format "44100:16:2"
}
VLC Player connects to stream rtp://239.9.3.2:5004 - let there be sound :)


mpd.log on satellite (MPD 0.19.12 from Bananian 15.08)

Code: Select all

Feb 11 16:14 : playlist: play 0:"rtp://239.9.3.2:5004"
Feb 11 16:14 : client: [3] command returned 0
Feb 11 16:14 : client: [3] process command "idle"
Feb 11 16:14 : client: [3] command returned 1
Feb 11 16:14 : decoder_thread: probing plugin ffmpeg
Feb 11 16:14 : ffmpeg: detected input format 'mp3' (MP2/3 (MPEG audio layer 2/3))
Feb 11 16:14 : ffmpeg/mp3: Header missing
Feb 11 16:14 : ffmpeg/mp3: Header missing
Feb 11 16:14 : ffmpeg/mp3: Header missing
(...)

Ouch. Ffmpeg autodetects mp3 instead of PCM. Is there a way to enforce ffmpeg's receiving codec?

Post Reply