Creating training movies with VNC2SWF

Posted by Steve on Tue 11 Oct 2005 at 05:26

Shockwave flash can be used for a lot of different things, from annoying web adverts to simple games. One interesting use for it is displaying movies. Movies you can record yourself by capturing on-screen activities. This is ideal for creating simple tutorials.

Using the vnc2swf tool you can record your interactions with a desktop, or single window, and share them to other people.

(We've previously introduced VNC, the Virtual Network Computer, so I'll only discuss the absolute minimum you need to get working here.)

To create your own movie you need two things:

  • A VNC server of some description.
  • The VNC2SWF program, and supporting Python libraries.

Optionally you'll need something that can create MP3 files to add audio to your movies. (If you wish to add audio I'd recommend you examine the audacity package)

Getting vnc2swf

vnc2swf isn't contained inside the Debian repository yet, so for the moment you must download it from the internet. You can find the current release here:

Download the python version of the software, (currently this is pyvnc2swf-0.6.4.tar.gz), and unpack it:

wget http://www.unixuser.org/~euske/vnc2swf/pyvnc2swf-0.6.4.tar.gz
tar -pzxvf pyvnc2swf-0.6.4.tar.gz
cd pyvnc2swf-0.6.4/

As the software is written in the Python scripting language there is no need to compile anything, you just need to have the relevent Python libraries installed upon your host.

To make this package work upon a Debian system you'll need to install python-tk, and python-pygame packages, which you can do with this command:

apt-get install python2.3-pygame python2.3-tk

Once that has been done you're ready to move on to the VNC server setup.

VNC Server Setup

For the VNC server I'm going to recommend you use the x11vnc package. This package allows you to create a VNC server sharing either your whole desktop, or just a single window. The latter is ideal for creating a simple training video.

Install the package with the following command, as root:

apt-get install x11vnc

If you wish to create a movie of your complete desktop you can run it as follows:

x11vnc -localhost -viewonly &

If you'd rather share a single window run:

x11vnc -localhost -viewonly -id pick &

This will allow you to click upon the window you wish to share with your mouse - after you have done so your selected window will be shared and made available.

Make Your Movie

Now that you have a running VNC server upon your local host you can create the movie. To do so execute:

./vnc2swf.py -nowindow -o myoutput.swf localhost

This will immediately connect to the VNC server you have running upon the localhost, and start recording a movie of anything that happens to that window. The output will be sent to myoutput.swf - and a HTML file will also be created called myoutput.html.

Load the output.html file into your browser and enjoy your movie!

Adding Sound

If you have an appropriate MP3 file you can add it to your movie file as follows:

./edit.py -a mymovie.mp3 -o output-with-audio.swf output.swf

Here we add the audio file mymovie.mp3 to the file we've just created (output.swf) and save the combined movie as output-with-audio.swf.

Sample Movie

This article wouldn't be complete without a sample. So here it is.

*shudder*

 

 


Posted by grimoire (60.36.xx.xx) on Tue 11 Oct 2005 at 13:37
Is there anything that can turn VNC into a more usable format like MPEG, which can ultimately be encoded using Theora or similar?

[ Parent | Reply to this comment ]

Posted by Anonymous (62.254.xx.xx) on Tue 11 Oct 2005 at 14:49
excellent, was wondering how to do this.

Ive been watching LinuxCBT Debian which uses a similar approach i believe, the whole cd set is screencam'd with audio to explain whats going on.

sno

[ Parent | Reply to this comment ]

Posted by Steve (82.41.xx.xx) on Tue 11 Oct 2005 at 15:24
[ View Steve's Scratchpad | View Weblogs ]

I'm afraid I'm unaware of such a tool, although I agree it would be more useful.

Googling for 'vnc2mpeg', 'vnc2avi', etc, failed to provide anything obvious - but I'd love to be suprised.

Steve
--

[ Parent | Reply to this comment ]

Posted by miguel (200.207.xx.xx) on Tue 11 Oct 2005 at 16:01
[ View Weblogs ]
xvidcap is what you are looking for.

[ Parent | Reply to this comment ]

Posted by Anonymous (213.164.xx.xx) on Tue 11 Oct 2005 at 16:06
Or even turning the SWF into a different format.
Switching from a vector format would make it big though.

[ Parent | Reply to this comment ]

Posted by Anonymous (71.111.xx.xx) on Tue 11 Oct 2005 at 19:33
Try vncrec, which records a VNC-format movie from a VNC session. You can watch it with "vncrec -play", or use transcode to encode it into a video. Note that the transcoding is very slow, as it just uses vncrec to dump each individual frame as an image, which is then read by transcode. It works, though.

[ Parent | Reply to this comment ]

Sign In

Username:

Password:

[Register|Advanced]

 

Flattr

 

Current Poll

What do you use for configuration management?








( 534 votes ~ 7 comments )

 

 

Related Links