Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #! /bin/bash
- #
- # FFMPEG transcoder for Youtube
- # For encoding settings see: https://support.google.com/youtube/answer/2853702?
- VBR="700k" # Bitrate of the video
- FPS="30" # Frames per second of the video
- YOUTUBE_URL="rtmp://a.rtmp.youtube.com/live2" # URL de base RTMP youtube
- SOURCE="udp://239.255.139.0:1234" # Source UDP
- KEY="" # The key you recieved from Youtube
- ffmpeg \
- -i "$SOURCE" \
- -c:v libx264 -pix_fmt yuv420p -vf "scale=-2:360" -r $FPS -g $(($FPS * 2)) -b:v $VBR \
- -c:a aac -ar 44100 -b:a 128k \
- -f flv "$YOUTUBE_URL/$KEY"
Advertisement
Add Comment
Please, Sign In to add comment