SF.net SVN: morphix: [2534] trunk/mmaker/utils/auto-testing
[email protected] Sat, 14 Jul 2007 15:31:26 -0700
| Newsgroups | gmane.linux.morphix.cvs |
|---|---|
| Message-ID | <[email protected]> |
Revision: 2534
http://svn.sourceforge.net/morphix/?rev=2534&view=rev
Author: bmsleight
Date: 2007-07-14 15:31:25 -0700 (Sat, 14 Jul 2007)
Log Message:
-----------
vncrec is much neater, frame capured every second - by tracking only the changes in frame buffer of vnc session, rather than whole screenshot. Hopefully HD will last longer.
Modified Paths:
--------------
trunk/mmaker/utils/auto-testing/Required-Packages.txt
trunk/mmaker/utils/auto-testing/auto_testing.sh
trunk/mmaker/utils/auto-testing/run_testing.sh
Modified: trunk/mmaker/utils/auto-testing/Required-Packages.txt
===================================================================
--- trunk/mmaker/utils/auto-testing/Required-Packages.txt 2007-07-12 21:11:58 UTC (rev 2533)
+++ trunk/mmaker/utils/auto-testing/Required-Packages.txt 2007-07-14 22:31:25 UTC (rev 2534)
@@ -12,6 +12,8 @@
build-essential
debhelper
+vncrec - from source
+
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
Modified: trunk/mmaker/utils/auto-testing/auto_testing.sh
===================================================================
--- trunk/mmaker/utils/auto-testing/auto_testing.sh 2007-07-12 21:11:58 UTC (rev 2533)
+++ trunk/mmaker/utils/auto-testing/auto_testing.sh 2007-07-14 22:31:25 UTC (rev 2534)
@@ -42,35 +42,14 @@
isomorph --add boot "splash=n debugmorphix=yes" $ISO $TMP_D/qemu.iso
qemu -vnc :1 -no-kqemu -full-screen -pidfile $TMP_D/qemu.pid -cdrom $TMP_D/qemu.iso &
sleep 2
-vncviewer -encodings raw -fullscreen -viewonly 127.0.0.1:1 &
-#vncviewer -fullscreen -viewonly 127.0.0.1:1 &
+VNCREC_MOVIE_FRAMERATE=1
+export VNCREC_MOVIE_FRAMERATE
+vncrec -geometry 800x600 -record /tmp/qemu.1.vnc :1 &
+sleep 10
+killall vncrec
+vncrec -fullscreen -record /tmp/qemu.2.vnc :1 &
+sleep $FRAMES
-l=16
-#xwininfo -root | grep wininfo | cut -d' ' -f 4 >$TMP_D/xwid
-#rootwindow=$(cat $TMP_D/xwid)
-while [ $l -lt $FRAMES ]
-do
- if [ "$l" -lt "10" ]
- then
- convert=$DUMPS'00'$l'.miff'
- elif [ "$l" -lt "100" ]
- then
- convert=$DUMPS'0'$l'.miff'
- if [ "$l" -eq "22" ]
- then
- echo "hi"
- killall vncviewer
- vncviewer -encodings raw -fullscreen -viewonly 127.0.0.1:1 &
- fi
- else
- convert=$DUMPS$l'.miff'
- fi
- import -display :0 -window root $convert
-# sleep 0.5
- l=$(expr $l + 1)
- echo "Frame " $convert " at " $(date +"%F_%H:%M:%S.%N")
-done
-
kill_pid=$(cat $TMP_D/qemu.pid)
kill $kill_pid
rm $TMP_D/qemu.iso
@@ -82,32 +61,53 @@
# Hey - it also looks pretty :)
convert $MINILOGO -resize 200x200 -negate -gravity South -background Black -font Helvetica-Bold -fill white -splice 0x36 -pointsize 35 -draw "text 0,0 'AutoTesting'" -transparent black $TMP_D/minilogo.gif
convert $TMP_D/minilogo.gif -fill grey50 -colorize 40 $TMP_D/minilogo.gif
+
+VNCREC_MOVIE_CMD="convert xpm:- /tmp/dump/image-%05d.png"
+export VNCREC_MOVIE_CMD
+vncrec -movie /tmp/qemu.1.vnc
l=16
-while [ $l -lt $FRAMES ]
+for i in $(ls /tmp/dump/image-*.png);
do
- if [ "$l" -lt "10" ]
- then
- convert=$DUMPS'00'$l'.miff'
- elif [ "$l" -lt "100" ]
- then
- convert=$DUMPS'0'$l'.miff'
- else
- convert=$DUMPS$l'.miff'
- fi
-
- echo "Converting $convert -> $convert.jpg"
-# convert $convert -resize 800x600 $convert.jpg
-#
- convert $convert -resize 800x600 $convert.jpg
+ if [ "$l" -lt "10" ]
+ then
+ convert=$DUMPS'00'$l'.miff'
+ elif [ "$l" -lt "100" ]
+ then
+ convert=$DUMPS'0'$l'.miff'
+ else
+ convert=$DUMPS$l'.miff'
+ fi
+ let l=l+1
+ echo $i "->" $convert
+ convert $i -resize 800x600 $convert.jpg
composite -dissolve 15 -gravity northeast $TMP_D/minilogo.gif $convert.jpg $convert.jpg
- rm $convert
- l=$(expr $l + 1)
done
+rm /tmp/dump/image-*
+vncrec -movie /tmp/qemu.2.vnc 1>/dev/null
+for i in $(ls /tmp/dump/image-*.png);
+do
+ if [ "$l" -lt "10" ]
+ then
+ convert=$DUMPS'00'$l'.miff'
+ elif [ "$l" -lt "100" ]
+ then
+ convert=$DUMPS'0'$l'.miff'
+ else
+ convert=$DUMPS$l'.miff'
+ fi
+ let l=l+1
+ echo $i "->" $convert
+ convert $i -resize 800x600 $convert.jpg
+ composite -dissolve 15 -gravity northeast $TMP_D/minilogo.gif $convert.jpg $convert.jpg
+done
+rm /tmp/dump/image-*
+
+
# Create the intro to the video
title="Autotesting using Qemu"
text=" $ISO - The iso has been amended to help debugging. The boot-options splash=n debugmorphix=y have been added and a MiniModule Morphix-Mini-Debug-Auto-Testing.mod added. This MiniModule prints out debug information to the screen, the iso does not normally contain this MiniModule or display this information. \n $LIST_ISOMORPH \n \n $COMMENTS"
-FOLD_TEXT==$(echo "$text" | fold -s -w 100 )
+FOLD_TEXT=$(echo "$text" | fold -s -w 100 )
convert -size 600x440 xc:white -pointsize 25 -fill darkblue -annotate 0x0+250+75 "$title" -pointsize 10 -fill blue -annotate 0x0+50+200 "$FOLD_TEXT" -append $LOGO -bordercolor darkblue -border 20x20 -flatten "$DUMPS"0.jpg
convert "$DUMPS"0.jpg -resize 800x600 "$DUMPS"1.jpg
mv "$DUMPS"1.jpg "$DUMPS"0.jpg
@@ -131,3 +131,5 @@
ffmpeg2theora $VIDEO --artist "AutoTesting" --title "$VIDEO $COMMENTS" --organization "www.morphix.org" --copyright "copyleft" --date "$TODAY"
rm $VIDEO
rm $TMP_D -r
+rm /tmp/qemu.2.vnc
+rm /tmp/qemu.1.vnc
Modified: trunk/mmaker/utils/auto-testing/run_testing.sh
===================================================================
--- trunk/mmaker/utils/auto-testing/run_testing.sh 2007-07-12 21:11:58 UTC (rev 2533)
+++ trunk/mmaker/utils/auto-testing/run_testing.sh 2007-07-14 22:31:25 UTC (rev 2534)
@@ -174,7 +174,7 @@
echo $DIVIDER
sudo isomorph --list $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN
echo $DIVIDER
- sudo /home/morph/morphix/trunk/mmaker/utils/auto-testing/auto_testing.sh $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN $VID_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN.avi 700
+ sudo /home/morph/morphix/trunk/mmaker/utils/auto-testing/auto_testing.sh $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN $VID_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN.avi 800
sudo rm $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN
echo $TMP_ISO_DIR/$TMP_MAINMODS_BN'_'$TMP_BASES_BN
gzip -c $LOG_FILE >$VID_DIR/$LOG_FILE_BN'_'$TODAY'_.gz'
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/