public class BitmapImageFactory
extends java.lang.Object
We put these factory methods into this class instead of into class BitmapImage, because we don't want to put this additional code into Java applets that don't need this functionality.
Modifier and Type | Method and Description |
---|---|
static BitmapImage |
toBitmapImage(java.awt.image.BufferedImage mis) |
static BitmapImage |
toBitmapImage(ColorCyclingMemoryImageSource mis) |
static BitmapImage |
toBitmapImage(java.awt.image.MemoryImageSource mis) |
static java.awt.image.BufferedImage |
toBufferedImage(BitmapImage bm)
Creates a BufferedImage using the provided BitmapImage.
|
static java.awt.Image |
toMemoryImage(BitmapImage bm) |
static void |
write(BitmapImage bm,
java.io.File f) |
static void |
write(BitmapImage bm,
java.io.OutputStream out) |
public static java.awt.image.BufferedImage toBufferedImage(BitmapImage bm)
bm
- The BitmapImage holding the image data.public static java.awt.Image toMemoryImage(BitmapImage bm)
public static BitmapImage toBitmapImage(java.awt.image.MemoryImageSource mis)
public static BitmapImage toBitmapImage(ColorCyclingMemoryImageSource mis)
public static BitmapImage toBitmapImage(java.awt.image.BufferedImage mis)
public static void write(BitmapImage bm, java.io.File f) throws java.io.IOException
java.io.IOException
public static void write(BitmapImage bm, java.io.OutputStream out) throws java.io.IOException
java.io.IOException