plugorgau / eventstreamr-station

EventStreamr Station Manager
2 stars 1 forks source link

YouTube Streaming #80

Closed techman83 closed 9 years ago

techman83 commented 9 years ago

It'd be great if we could stream to YouTube.

Inspiration Here: https://gist.github.com/olasd/9841772

VBR="2500k"                                    
FPS="25"                                       
QUAL="medium"                                  
YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2"
SOURCE=$1
KEY="goes_here"

avconv \
    -i "$SOURCE" -deinterlace \
    -vcodec libx264 -pix_fmt yuv420p -vf scale=-1:480 -preset $QUAL -r $FPS -g $(($FPS * 2)) -b:v $VBR \
    -acodec libmp3lame -ar 44100 -threads 6 -qscale 3 -b:a 712000 -bufsize 512k \
    -f flv "$YOUTUBE_URL/$KEY"