Mit Linux und ffmpeg zu Youtube streamen

VBR=”3500k” # bitrate
FPS=”30″ # framerate
KEYFRAMEINT=”40″ # keyframe interval
QUAL=”medium” # ffpmeg quality preset
YOUTUBE_URL=”rtmp://″ # youtube rtmp url

sudo modprobe snd_aloop
alsactl restore
while true

ffmpeg -err_detect explode -thread_queue_size 16384 \
-f alsa -ac 2 -i pulse \
-f v4l2 -video_size 864×480 -thread_queue_size 16384 -i /dev/video1 -deinterlace \
-vcodec libx264 -pix_fmt yuv420p -preset $QUAL -r $FPS -g $KEYFRAMEINT -b:v $VBR \
-acodec libmp3lame -ar 44100 -threads 6 -qscale 3 -b:a 712000 -bufsize 512k \
-f flv “$YOUTUBE_URL/$KEY”

sleep 5

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.