Linux.com

xorg/ImageMagick/mencoder hack for scrncap to xv

Posted by: Anonymous Coward on September 23, 2006 12:56 AM
xvidcap was one of the best I've seen for this but it isn't well maintained and doesn't currently work for me ffmpeg mutated too much. I've gotten some mileage out of something like:

xwinid=`xwininfo|grep "Window id:"|awk '{print $4}'`

while [ 1=1 ]
do

    nowtime=`date +%Y%m%d%H%M%S%N`

    xwd -id $xwinid |gzip -1 > screencap.$nowtime.xwd.gz
done

gunzip *.xwd.gz
mogrify -format jpmencoder "mf://*.$in_type" -mf fps=$outfps -o amovie.xvid -ovc xvid -xvidencopts bitrate=2400 #-oac mp3lame -lameopts cbr:br=128g *.xwd

A bit of a hassle post processing to convert the frames to a movie but i get about 3-5fps on a AMD-64 3100

#

Return to Create training videos with pyvnc2swf