This is an archive of the old MediaWiki-based ImageJ wiki. The current website can be found at

3D Viewer: Record a Movie

(Return to the Developer Documentation page)
(Return to the main 3D_Viewer page)

How to animate the universe and create movies

You can download example source code for this HowTo here.

It is very easy to animate the virtual universe and to record the animation, so that it can be stored as a video file and as such easily embedded into presentations.

The following lines show an easy example:

	// Add the image as a volume

	// animate the universe

	// record a 360 degree rotation around the y-axis
	ImagePlus movie = univ.record360();;

The call to the universe's record() method returns an ImagePlus, which consists of a stack of successive frames of a full 360 degree animation.

ImageJ provides methods to save such a stack for example as AVI file or as animated GIF.