QuickTime Extension

What does the QuickTime Extension do?

The QuickTime Extension allows you to interact with and create images for importing from webcams and movie files.

Installing the QuickTime Extension


First, make sure you have QuickTime installed if you don't you can download it here:


A few files from your QuickTime installation need to be moved into the extension directory in order for the video extension to work.

You will also need to install a digitizer, we recommend WinVDIG which can be downloaded here:


You must install version 1.0.1 not a newer version.

You can then test that QTJ and the digitizer are installed correctly through their test application QTCap. (If you have trouble, see Contacting Us.)

On Windows Vista you will need to start NetLogo as administrator in order to use the video extension. You can do so by right clicking on the executable and selecting "Run As Administrator". You can also permanently change this setting: open the properties dialog, select the Compatibility tab and select "Run As Administrator" checkbox.

Mac OS X

A few files from your QuickTime installation need to be moved into the extension directory in order for the video extension to work.

Also, on 64-bit Macs (which includes all currently sold models), you will need to change NetLogo to run in 32-bit mode in order to use the extension. If you don't, the usual result is a java.lang.UnsatisfiedLinkError dialog. Here are the steps to follow:

If you want, you can make a copy of the application first and performs these steps on the copy, so the original still opens in 64-bit mode. (64-bit mode is the recommended default unless you are using this extension.)


The QuickTime Extension is not compatible with Linux, because Apple does not have a Linux version of QuickTime.

Getting started

To import images from webcams and movies into NetLogo you will need to include both the QTJ and the Bitmap Extensions.

extensions[ bitmap qtj ]

There are two code examples that present the basic functions of these extensions.

Code Example: QuickTime Extension/QuickTime Camera Example
Code Example: QuickTime Extension/QuickTime Movie Example


qtj:camera-image qtj:camera-select qtj:camera-start qtj:camera-stop qtj:movie-close qtj:movie-image qtj:movie-open qtj:movie-open-player qtj:movie-set-time qtj:movie-start qtj:movie-stop



Returns an image from the currently open camera suitable for importing with the bitmap extension


qtj:camera-select width height

Offers a dialog of installed cameras for you to choose from. When you select one a connection is opened with the selected camera at the given resolution. If you use camera-select you do not need to call camera-start. You must call either select or start before using camera-image.


qtj:camera-start width height

Opens the connected camera at the given resolution (given in patches) and prepares it to grab images. You must always call camera-start or camera-select before using camera-image. You should not use camera-start when the camera is already open. To select a different camera use camera-stop then camera-select.



Closes the connected camera. You should always stop the camera before exiting NetLogo or before opening a new model.



Closes the currently open movie, disposes of any related resources including the player window. You should always close a movie before opening a new one or before exiting NetLogo.



Returns an image of the current frame of the open movie suitable for importing with the bitmap extension.


qtj:movie-open width height

Loads the specified movie at the specified resolution (given in patches).



Opens a window where you can view the open movie.


qtj:movie-set-time seconds

Changes the frame of the movie to the frame corresponding to the given time.



Starts playing the movie.



Stops playing the movie.