swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Support] saving swarm images


From: Vegard Hartmann
Subject: Re: [Swarm-Support] saving swarm images
Date: Tue, 19 Oct 2004 14:51:48 +0200 (MEST)

Does anyone know of a program that runs under linux that will create a movie from png files?

Vegard

On Mon, 18 Oct 2004, Steve Railsback wrote:

Mark Alexiuk wrote:
Hi,

Could someone remind me how to save a series of images or screenshots
from a swarm simulation?
I am using the Fedora Core version.

Thanks a lot,
Mark Alexiuk


Here is an example method that writes the raster object "worldRaster" to a .png file each time it is called ... it is called once per time step, and the file name includes the time step number (currentTime).

If you skip the "setWidget" command, it grabs the whole screen.

I use some shareware called GIF Construction Set to assemble the .png files into a movie. I'm sure there are other ways.

Steve R.

-(void) writeFrame {
 char filename[256];
 id pixID;

sprintf(filename, "Model%03d_Frame%03ld.png", modelNumber, getCurrentTime());

pixID =  [Pixmap createBegin: [self getZone]];
[pixID  setWidget: worldRaster];
pixID = [pixID createEnd];
[pixID save: filename];
[pixID drop];

}






reply via email to

[Prev in Thread] Current Thread [Next in Thread]