net.aerith.misao.image.io
Class JimiFormat
java.lang.Object
|
+--net.aerith.misao.image.io.Format
|
+--net.aerith.misao.image.io.JimiFormat
- Direct Known Subclasses:
- Bmp, Gif, Jpeg, Png, Tiff
- public abstract class JimiFormat
- extends Format
- implements Bitmap
The JimiFormat is an abstract class to read and save
image file supported by JIMI. It is just an access interface to the
file.
| Fields inherited from class net.aerith.misao.image.io.Format |
url |
|
Method Summary |
abstract java.lang.String |
getMimeType()
Gets the MIME type ID. |
MonoImage |
read()
Reads image file and creates image buffer. |
private void |
save(java.awt.Image image)
Saves a java.awt.Image into an image file. |
void |
save(MonoImage image)
Saves image buffer into an image file. |
void |
save(MonoImage image,
LevelAdjustmentSet set)
Saves an image buffer into an image file, using the specified
LevelAdjustmentSet. |
| Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
toString,
wait,
wait,
wait |
JimiFormat
public JimiFormat()
getMimeType
public abstract java.lang.String getMimeType()
- Gets the MIME type ID.
- Returns:
- the MIME type ID.
read
public MonoImage read()
throws java.io.IOException,
UnsupportedBufferTypeException,
UnsupportedFileTypeException
- Reads image file and creates image buffer. The url of the image
file must be set previously.
- Overrides:
- read in class Format
- Returns:
- the monochrome image buffer.
- Throws:
- java.io.IOException - if I/O error occurs.
- UnsupportedBufferTypeException - if the data type is
unsupported.
- UnsupportedFileTypeException - if the file type is
unsupported.
save
public void save(MonoImage image)
throws java.io.IOException,
UnsupportedBufferTypeException,
UnsupportedFileTypeException
- Saves image buffer into an image file. The url of the image file
must be set previously.
- Overrides:
- save in class Format
- Parameters:
image - the monochrome image buffer to save.- Throws:
- java.io.IOException - if I/O error occurs.
- UnsupportedBufferTypeException - if the data type is
unsupported.
- UnsupportedFileTypeException - if the file type is
unsupported.
save
public void save(MonoImage image,
LevelAdjustmentSet set)
throws java.io.IOException,
UnsupportedFileTypeException
- Saves an image buffer into an image file, using the specified
LevelAdjustmentSet. The url of the image file
must be set previously.
- Specified by:
- save in interface Bitmap
- Parameters:
image - the monochrome image buffer to save.- Throws:
- java.io.IOException - if I/O error occurs.
- UnsupportedFileTypeException - if the file type is
unsupported.
save
private void save(java.awt.Image image)
throws java.io.IOException,
UnsupportedBufferTypeException,
UnsupportedFileTypeException
- Saves a
java.awt.Image into an image file.
- Parameters:
image - the java.awt.Image.- Throws:
- java.io.IOException - if I/O error occurs.
- UnsupportedBufferTypeException - if the data type is
unsupported.
- UnsupportedFileTypeException - if the file type is
unsupported.