Image to BufferedImage ?
1 posts in topic
Flat View  Flat View

Posted By:   miguel_Burbano
Posted On:   Thursday, March 7, 2002 11:02 AM

how i convert an Image object to an BufferedImage Object?

Re: Image to BufferedImage ?

Posted By:   Anonymous  
Posted On:   Friday, March 8, 2002 02:04 AM

Maybe this example that comes from the Java2D O'Reilly book could help you:

public static BufferedImage makeBufferedImage(Image image, int imageType) {

BufferedImage bufferedImage = new BufferedImage(
image.getWidth(null), image.getHeight(null),
Graphics2D g2 = bufferedImage.createGraphics();
g2.drawImage(image, null, null);
return bufferedImage;

About | Sitemap | Contact