That's "fixed" in the latest release. The fix is not really a fix as the bug is still there but it throws an exception early before running out of memory.
> -----Original Message----- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] On > Behalf Of paul_deg > Sent: Monday, June 20, 2005 5:18 PM > To: itext-questions@lists.sourceforge.net > Subject: [iText-questions] out of memory error on certain TIFF images > > I use iText to parse TIFF images (get 2 JPEGs from it) > and then embedd them into PDF. For some TIFFs I get > the following exception: > > > [6/14/05 9:53:57:347 CDT] 6574d2a6 SystemErr R > java.lang.OutOfMemoryError > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.ByteBuffer.a > ppend_i(ByteBuffer.java(Inlined Compiled Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.ByteBuffer.a > ppend(ByteBuffer.java(Inlined Compiled Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.codec.CCITTG > 4Encoder.add1DBits(CCITTG4Encoder.java(Compiled Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.codec.CCITTG > 4Encoder.encodeT6Line(CCITTG4Encoder.java(Compiled > Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.codec.CCITTG > 4Encoder.encodeT6Lines(CCITTG4Encoder.java(Compiled > Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.codec.TiffIm > age.getTiffImage(TiffImage.java(Compiled Code)) > [6/14/05 9:53:57:348 CDT] 6574d2a6 SystemErr R > at com.lowagie.text.pdf.codec.TiffIm > age.getTiffImage(TiffImage.java(Inlined Compiled > Code)) > > > I use this code: > > RandomAccessFileOrArray ra = null; > int comps = 0; > ra = new > RandomAccessFileOrArray(checkImage); > comps = TiffImage.getNumberOfPages(ra); > > > System.out.println("RA array length: " + > ra.length()); > > for (int c = 0; c < comps; ++c) { > > if (log.isDebugEnabled()) { > log.debug("Getting TIFF image #: " + c); > > } > > Image img = TiffImage.getTiffImage(ra, c + > 1, true); > > Tried to use non-"direct" mode for > TiffImage.getTiffImage - same effect. Image size > varies from 15 to 40 KB. > What is wrong? Any suggestions? > > > > __________________________________ > Discover Yahoo! > Use Yahoo! to plan a weekend, have fun online and more. Check it out! > http://discover.yahoo.com/ > > > ------------------------------------------------------- > SF.Net email is sponsored by: Discover Easy Linux Migration Strategies > from IBM. Find simple to follow Roadmaps, straightforward articles, > informative Webcasts and more! Get everything you need to get up to > speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click > _______________________________________________ > iText-questions mailing list > iText-questions@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/itext-questions > ------------------------------------------------------- SF.Net email is sponsored by: Discover Easy Linux Migration Strategies from IBM. Find simple to follow Roadmaps, straightforward articles, informative Webcasts and more! Get everything you need to get up to speed, fast. http://ads.osdn.com/?ad_idt77&alloc_id492&op=click _______________________________________________ iText-questions mailing list iText-questions@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/itext-questions