Live Stream IP Camera (no audio) to Facebook using FFmpeg

Live Stream IP Camera (no audio) to YouTube using FFmpeg: https://youtu.be/MM2oTTb5zXg

FFmpeg notes (including FFmpeg install): https://www.rickmakes.com/ffmpeg-notes/

FFmpeg playlist: https://www.youtube.com/playlist?list=PLErU2HjQZ_ZOPDZ71Khzt5PX4X4j6flkg

Amcrest playlist: https://www.youtube.com/playlist?list=PLErU2HjQZ_ZNYE224qh9K0hhaaIxU-rta

Live Stream Recommended Settings

https://www.facebook.com/business/help/162540111070395?id=1123223941353904&recommended_by=167417030499767

Facebook Live Stream URL

https://www.facebook.com/live/create

Stream to Facebook (FFmpeg scales video)
ffmpeg -f lavfi -i anullsrc -rtsp_transport udp -i "rtsp://username:password@ip_address:554/cam/realmonitor?channel=1&subtype=0" -force_key_frames "expr:gte(t,n_forced*2)" -vf crop=in_w:in_w*9/16,scale=1280:720 -reorder_queue_size 4000 -max_delay 10000000 -vcodec libx264 -b:v 4500k -pix_fmt yuv420p -f flv "facebook_url"
Stream to Facebook (IP camera scales video)
ffmpeg -f lavfi -i anullsrc -rtsp_transport udp -i "rtsp://username:password@ip_address:554/cam/realmonitor?channel=1&subtype=0" -force_key_frames "expr:gte(t,n_forced*2)" -reorder_queue_size 4000 -max_delay 10000000 -vcodec copy -pix_fmt yuv420p -f flv "facebook_url"
Use Hardware Encoding on Mac

Change libx264 to h264_videotoolbox

Use Hardware Encoding on Windows (Intel processor, QuickSync)

Change libx264 to h264_qsv

Leave a comment

Your email address will not be published. Required fields are marked *