Advertisement
Guest User

Untitled

a guest
Dec 13th, 2011
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.91 KB | None | 0 0
  1.  
  2. function streaming() {
  3. INRES="1600x900" # input resolution
  4. OUTRES="640x360"
  5. FPS="15" # target FPS
  6. QUAL="fast" # one of the many FFMPEG preset
  7. STREAM_KEY="$1"
  8. URL="rtmp://live.justin.tv/app/$STREAM_KEY" #flashver=FMLE/3.0\20(compatible;\20FMSc/1.0)"
  9.  
  10. ffmpeg -f alsa -ac 2 -i hw:0,0 -acodec libmp3lame -ab 96k \ -f x11grab -s "$INRES" -r "$FPS" -i :0.0 \
  11. -vcodec libx264 -b:v 600k -minrate 300k -maxrate 700k -bufsize 1835k -s "$OUTRES" -level 30 -f mpegts \
  12. -f flv "$URL"
  13.  
  14. }
  15.  
  16.  
  17. I am trying to 1. capture and stream video at a max bitrate of 600 KB/SEC - not sure if that is happening, secondly I get an error when I execute script:
  18.  
  19. Input #0, alsa, from 'hw:0,0':
  20. Duration: N/A, start: 1323835311.943045, bitrate: N/A
  21. Stream #0:0: Audio: pcm_s16le, 48000 Hz, 2 channels, s16, 1536 kb/s
  22. [NULL @ 0x10de640] Unable to find a suitable output format for ' -f'
  23. -f: Invalid argument
  24.  
  25.  
  26. TY FOR YOUR HELP! :D
  27.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement