Creating and drawing are two different operations.  Once a MemoryImageSource
is initialized.  You use newPixels() to update the image you created
with MemoryImageSource and then you draw the updated image.

Your snippet should look something like:

    mis = new MemoryImageSource(thisW, thisH, ColorModel.getRGBdefault(), 
pixels, 0, thisW);
        mis.setAnimated(true);
        mis.setFullBufferUpdates(true);
        canvasImage = this.createImage(mis);

Then you use mis.newPixels() to update the canvasImage you created with MIS
with your new image in pixels.

The real test is to draw 10,000 times to the screen  -- not how long
it takes to create one BufferedImage or one image from MemoryImageSource.

I'm always interested in different perspectives -- please post test
code if you get around to it.
[Message sent by forum member 'demonduck' (demonduck)]

http://forums.java.net/jive/thread.jspa?messageID=284838

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to