# SAMPLE: FLAC streaming on Windows & Mac # Input device on Windows # you should find DShow device name by: # ffmpeg.exe -list_devices true -f dshow -i dummy input="dshow" device="audio=@device_cm_{33D9A762-90C8-11D0-BD43-00A0C911CE86}\wave_{D50ABAB1-D542-4F19-BB77-D12FADCAB889}" # Input device on macOS # setup a default device at System Preferences > Sound > Input # input="avfoundation" # device="none:default" channels=2 samplerate=48000 codec="flac" # above 12 is not recommended # if you have a slow hardware, set lower value. level=10 while true do ./ffmpeg -f $input \ -i $device \ -ar $samplerate \ -ac $channels \ -c:a $codec -compression_level $level \ -f ogg \ -content_type 'application/ogg' \ icecast://source:PASSWORD@HOSTNAME:8001/STREAM_NAME sleep 1 done