Created
March 9, 2016 19:19
-
-
Save kabakaev/c1bb002919c50f0e97d5 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash -x | |
| echo this command will stream from macbook pro FaceTime webcam to youtube | |
| echo you may wish to run \"brew install ffmpeg\" to get it working | |
| youtube_streaming_key=$1 | |
| [ -Z "$youtube_streaming_key" ] && youtube_streaming_key='xxxx-xxxx-xxxx-xxxx' | |
| youtube_rtmp_url='rtmp://a.rtmp.youtube.com/live2' | |
| ffmpeg -video_size 1280x720 -framerate 30 -f avfoundation -i "0:0" -vcodec libx264 -preset ultrafast -maxrate 1984k -bufsize 3968k -vf "format=yuv420p" -g 60 -acodec libvo_aacenc -b:a 128k -ar 44100 -f flv $youtube_rtmp_url/$youtube_streaming_key |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment