View Single Post
  #1 (permalink)  
Old 01-23-2008, 11:53 PM
tim's Avatar
tim tim is offline
Senior Member
 
Join Date: Dec 2007
Location: South Africa
Posts: 334
tim is on a distinguished road
BuffededImage cache
Hello everyone

I've been using BufferedImage objects for some time and I noticed something strange. When I use the ImageIO.read() method to read an image from the hard drive and I draw the image somewhere in a thread, I found that it is very slow. But, if I load the image in some BufferedImage object, say A, create a new Instance of BufferedImage B and draw A onto B using the BufferedImage.getGraphics() method, I found that rendering B is much faster. Can someone please explain this and perhaps show me a better way of using the BufferedImage for performance.

Thank you
__________________
If your ship has not come in yet then build a lighthouse.
Reply With Quote
Sponsored Links