We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › saveFrame() and pixels[]
Page Index Toggle Pages: 1
saveFrame() and pixels[] (Read 411 times)
saveFrame() and pixels[]
Jun 18th, 2007, 4:35pm
 
I have a program that goes something like:

setup(){
 setup stuff
 loadPixels();
}

draw(){
 updatePixels();
 draw stuff
 loadPixels();
 draw more stuff
}

void mousePressed{
 saveFrame("blah###.png");
}


the point is to have something move around and leave a trail.

the problem is that when saveFrame() is called, it saves the floating thing into the background.

I managed to keep that from happening by loading pixels into another array, then back after saveFrame() has been called, but this slows it down a bunch.

any suggestions?

Re: saveFrame() and pixels[]
Reply #1 - Jun 18th, 2007, 6:01pm
 
http://processing.org/learning/examples/storinginput.html

http://processing.org/learning/topics/follow3.html

2 ways to simulate trails or follow-up..

if u want to leave the trail like until you quit the application simple dont clean the buffer with the background() function
Page Index Toggle Pages: 1