Advertisement
Guest User

FFMpeg screencast window

a guest
Feb 2nd, 2011
281
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.39 KB | None | 0 0
  1. #!/bin/sh
  2.  
  3. INFO=$(xwininfo -frame)
  4.  
  5. WIN_GEO_W=$(echo $INFO | grep 'Width' | awk '{print $2;}')
  6. WIN_GEO_H=$(echo $INFO | grep 'Height' | awk '{print $2;}')
  7. WIN_X=$(echo $INFO | grep 'Absolute upper-left X' | awk '{print $4;}')
  8. WIN_Y=$(echo $INFO | grep 'Absolute upper-left Y' | awk '{print $4;}')
  9.  
  10. ffmpeg -f x11grab -r 25 -s $WIN_GEO_Wx$WIN_GEO_H -i :0.0+$WIN_X+$WIN_Y /tmp/screencast.avi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement