Switch to web radio audio source

This commit is contained in:
douzeb 2023-03-02 15:13:31 +01:00
parent 5502ca423c
commit b132c922f2
1 changed files with 7 additions and 8 deletions

View File

@ -41,23 +41,22 @@ echo Will stream to $URL
echo and save a copy of the data file :
echo $FILENAME
# A la ligne 76, utiliser cette ligne pour avoir un son de test généré par ffmpeg :
# A la ligne xx, utiliser cette ligne pour avoir un son de test généré par ffmpeg :
# -f lavfi -i aevalsrc="(1-min(1\,mod(floor(5*t)\,50)))*0.1*sin(8*PI*(360-2.5/2)*t)+0.1*sin(2*PI*(360-2.5/2)*t)|(1-min(1\,mod(floor(5*t)\,50)))*0.1*sin(8*PI*(360+2.5/2)*t)+0.1*sin(2*PI*(360+2.5/2)*t):sample_rate=48000" \
# A la ligne 76, utiliser cette ligne pour avoir le son de la caméra :
# A la ligne xx, utiliser cette ligne pour avoir le son de la caméra :
#-f alsa -ac 2 -i hw:CARD=CAMERA,DEV=${V4LDEVICE} \
#-x264opts nal-hrd=cbr:force-cfr=1:vbv-bufsize=${BUFFERSIZE}:bitrate=${VBITRATE}:vbv-maxrate=${VBITRATE} \
#-codec:v libx264 \
#-preset superfast \
#-pixel_format yuv420p \
# A la ligne xx, utiliser cette ligne pour avoir le son d'une web radio :
#-f ogg -ac 2 -i http://91.121.159.124:8000/eko-des-garrigues-96k.ogg \
ffmpeg \
-loglevel level \
-y \
-f v4l2 -framerate ${FPS} -video_size ${REPLAY_RESOLUTION} -input_format mjpeg -i /dev/video${V4LDEVICE} \
-f lavfi -i aevalsrc="(1-min(1\,mod(floor(5*t)\,50)))*0.1*sin(8*PI*(360-2.5/2)*t)+0.1*sin(2*PI*(360-2.5/2)*t)|(1-min(1\,mod(floor(5*t)\,50)))*0.1*sin(8*PI*(360+2.5/2)*t)+0.1*sin(2*PI*(360+2.5/2)*t):sample_rate=48000" \
-f v4l2 -framerate 30 -video_size ${REPLAY_RESOLUTION} -input_format mjpeg -i /dev/video${V4LDEVICE} \
-f ogg -ac 2 -i http://91.121.159.124:8000/eko-des-garrigues-96k.ogg \
-channel_layout stereo \
-ar 48000 \
-filter_complex "[1:a]volume=-10dB;[0:v]drawtext='font=DejaVuSansMono:text=%{pts}: fontcolor=white: fontsize=h/12: box=1: boxcolor=black@0.43: boxborderw=5: x=mod(floor(t/10+1)\,2)*mod(t*(w-text_w)/10\,w-text_w)+mod(floor(t/10)\,2)*(w-text_w-mod(t*(w-text_w)/10\,w-text_w)): y=text_h/2', drawtext='font=DejaVuSansMono:text=%{localtime}: fontcolor=white: fontsize=h/20: box=1: boxcolor=black@0.43: boxborderw=5: x=text_h: y=h-3*text_h/2', split=2[out1][out2]" \