I have Raspberry pi 3 model b. I stream video and sound (from dedicated camera + usb sound card) to Youtube by command:
raspivid -o - -t 0 -vf -hf -fps 30 -b 600000 | ffmpeg -i pipe: -f alsa -ac 1 -i plughw:1,0 -vcodec copy -acodec aac -ab 128k -g 50 -strict experimental -f flv rtmp://a.rtmp.youtube.com/live2/<my-code>
And this is effect:
https://www.youtube.com/watch?v=fEWEEpJQgy8
We can hear the "clap" in 15-16 second, but we can see it in 24s.
How can I synchronize sound with video? Or how can I set the delay of sound? I was trying yet use this command:
raspivid -o - -t 0 -vf -hf -fps 25 -b 600000 | ffmpeg -i pipe: -f alsa -ac 1 -itsoffset 10.00 -i plughw:1,0 -map 0:v -map 1:a -vcodec copy -acodec aac -ab 128k -g 50 -strict experimental -f flv rtmp://a.rtmp.youtube.com/live2/<my-code>
but it didn't help - the delay of video is still.
Any suggestions?