aboutsummaryrefslogtreecommitdiffstats
path: root/src/java-1.4
diff options
context:
space:
mode:
authorJeremias Maerki <jeremias@apache.org>2005-08-21 16:44:00 +0000
committerJeremias Maerki <jeremias@apache.org>2005-08-21 16:44:00 +0000
commitb5fe4766be47aa3394b7d8d98422c983b246a73c (patch)
treec6643113fd815d1566ea9db6e9354f4ce27b5597 /src/java-1.4
parentf5b4eeff769eafa0f2020d4766d25afc675f6142 (diff)
downloadxmlgraphics-fop-b5fe4766be47aa3394b7d8d98422c983b246a73c.tar.gz
xmlgraphics-fop-b5fe4766be47aa3394b7d8d98422c983b246a73c.zip
Bugzilla #36224:
This patch ports the 0.20.5 CCITTFaxDecode filter functionality and its support of direct embedding on certain TIFF images to the trunk. It also cleans up some of the image handling with respect to consistent closing of the input stream to avoid dangling open files. Submitted by: Manuel Mall <mm.at.arcus.com.au> Changes to the patch: Fixed a small problem with the NullFilter in the PDF library. Used tiff_group4.tiff in external-graphic-tiff.xml. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@234261 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java-1.4')
-rw-r--r--src/java-1.4/org/apache/fop/image/ImageIOImage.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/java-1.4/org/apache/fop/image/ImageIOImage.java b/src/java-1.4/org/apache/fop/image/ImageIOImage.java
index 369bb6e8d..882f36d92 100644
--- a/src/java-1.4/org/apache/fop/image/ImageIOImage.java
+++ b/src/java-1.4/org/apache/fop/image/ImageIOImage.java
@@ -42,9 +42,20 @@ public class ImageIOImage extends AbstractFopImage {
super(info);
}
+ /**
+ * @see org.apache.fop.image.AbstractFopImage#loadDimensions()
+ */
+ protected boolean loadDimensions() {
+ if (this.bitmaps == null) {
+ return loadBitmap();
+ }
+ return true;
+ }
+
/** @see org.apache.fop.image.AbstractFopImage#loadBitmap() */
protected boolean loadBitmap() {
try {
+ inputStream.reset();
BufferedImage imageData = ImageIO.read(inputStream);
this.height = imageData.getHeight();