Interface BitmapEncoder
- All Known Implementing Classes:
ImageIOBitmapEncoder
public interface BitmapEncoder
This interface is used to encode bitmaps into their target formats.
- Version:
- $Id: BitmapEncoder.java,v 1.2 2004-09-04 20:25:54 jmaerki Exp $
- Author:
- Jeremias Maerki
-
Method Summary
Modifier and TypeMethodDescriptionvoidencode(BufferedImage image, OutputStream out, String mime, int resolution) Encodes a BufferedImage to a target format and writes it to the OutputStream.String[]Returns an array of MIME types supported.
-
Method Details
-
getSupportedMIMETypes
String[] getSupportedMIMETypes()Returns an array of MIME types supported.- Returns:
- the array of MIME types
-
encode
Encodes a BufferedImage to a target format and writes it to the OutputStream.- Parameters:
image- the image to encodeout- the OutputStream to write the image tomime- the MIME type in which to encode the imageresolution- the resolution in dpi of the image- Throws:
IOException- in case of an I/O problem
-