mirror of
https://github.com/haraldk/TwelveMonkeys.git
synced 2026-05-28 00:00:03 -04:00
Better writer tests.
Fixed a bug in PICTWriter. Minor changes in ImageReader/WriterBase classes.
This commit is contained in:
@@ -99,9 +99,13 @@ public abstract class ImageReaderBase extends ImageReader {
|
||||
public void setInput(final Object input, final boolean seekForwardOnly, final boolean ignoreMetadata) {
|
||||
resetMembers();
|
||||
super.setInput(input, seekForwardOnly, ignoreMetadata);
|
||||
|
||||
if (input instanceof ImageInputStream) {
|
||||
imageInput = (ImageInputStream) input;
|
||||
}
|
||||
else {
|
||||
imageInput = null;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -83,6 +83,9 @@ public abstract class ImageWriterBase extends ImageWriter {
|
||||
if (output instanceof ImageOutputStream) {
|
||||
imageOutput = (ImageOutputStream) output;
|
||||
}
|
||||
else {
|
||||
imageOutput = null;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user