voyent
java.lang.OutOfMemoryError: Java heap space  XML
Forum Index -> ICEpdf General
Author Message
suraj1992

Joined: 07/Oct/2015 11:02:32
Messages: 10
Offline


Hi All
I am working on a swing based project
where I open PDF many times
for 2,3,or 4 times it works fine but after it it gives exception


Code:
Oct 21, 2015 5:57:14 PM org.icepdf.core.pobjects.graphics.ImageStreamReference call
 WARNING: Error loading image: 1314 0R Image stream= {BitsPerComponent=8, Name=X, Filter=DCTDecode, Subtype=Image, Type=XObject, Length=1064500, Height=2515, Metadata=1313 0R, Width=4110, ColorSpace=DeviceRGB}  1314 0R
 java.lang.OutOfMemoryError: Java heap space
 	at java.awt.image.DataBufferInt.<init>(DataBufferInt.java:75)
 	at java.awt.image.Raster.createPackedRaster(Raster.java:467)
 	at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:1032)
 	at org.icepdf.core.pobjects.ImageUtility.makeBufferedImage(ImageUtility.java:243)
 	at org.icepdf.core.pobjects.ImageUtility.convertYCbCrToRGB(ImageUtility.java:941)
 	at org.icepdf.core.pobjects.ImageStream.dctDecode(ImageStream.java:556)
 	at org.icepdf.core.pobjects.ImageStream.getImage(ImageStream.java:342)
 	at org.icepdf.core.pobjects.ImageStream.getImage(ImageStream.java:288)
 	at org.icepdf.core.pobjects.graphics.ImageStreamReference.call(ImageStreamReference.java:73)
 	at org.icepdf.core.pobjects.graphics.ImageStreamReference.call(ImageStreamReference.java:39)
 	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
 	at java.lang.Thread.run(Thread.java:745)


please have a look and let me know if there is any solution.
my pdf consist of Images. 1 Images Per page.

Thanks in Advance
patrick.corless

Joined: 26/Oct/2004 00:00:00
Messages: 1969
Offline


If your using our default ViewerRI then it's very important that you call swingController.closeDocument() to insure that a documents resources are correctly released.
[Email]
 
Forum Index -> ICEpdf General
Go to:   
Powered by JForum 2.1.7ice © JForum Team