This seems like a simple question, but I cannot find the answer.
I have this code:
import com.adobe.images.PNGEncoder;
var fr:FileReference = new FileReference();
var pngSource:BitmapData = new BitmapData (stage.width, stage.height);
pngSource.draw(sketch_mc);
var ba:ByteArray = PNGEncoder.encode(pngSource);
fr.save(ba,'alon20.png');
which saves me the image. I want it to be autosave and not open the dialog box as it is now. the reason I want this to happen is that I want to take a snapshot of each frame during rendering (make a movie out of it).
What am I missing?
Alon source
share