Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- # Stream from Linux to Twitch/Justin
- INRES="1366x768" # input resolution
- OFFSET="0,0"
- OUTRES="1280x720"
- FPS="15" # target FPS
- QUAL="ultrafast" # one of the many FFMPEG preset
- STREAM_KEY="live_PUT-YOUR-STREAM-KEY-HERE"
- URL="rtmp://live.justin.tv/app/$STREAM_KEY"
- avconv -f x11grab -s "$INRES" -r "$FPS" -i :0.0+$OFFSET -b 256k \
- -vcodec libx264 -crf 30 -b:v 1000k -s "$OUTRES" \
- -f flv "$URL"
- # Same but with audio
- #avconv -f x11grab -s "$INRES" -r "$FPS" -i :0.0+$OFFSET -b 256k \
- # -f alsa -ac 2 -i pulse -ar 44100 -itsoffset -25 \
- # -vcodec libx264 -crf 30 -b:v 1000k -s "$OUTRES" \
- # -acodec libmp3lame -b:a 128k \
- # -f flv "$URL"
Add Comment
Please, Sign In to add comment