incubator-sanselan-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Craig L Russell <Craig.Russ...@Sun.COM>
Subject Re: EXIF on Jpeg brings Out Of Memory
Date Wed, 11 Jun 2008 21:22:02 GMT
If possible, can you create a JIRA issue and attach the failing file?

https://issues.apache.org/jira/browse/SANSELAN

Thanks,

Craig

On Jun 10, 2008, at 8:30 AM, Charles Matthew Chen wrote:

> Hi Christian,
>
>   Can you please send me a sample image that reproduces this issue?
>
> Thanks,
>   Charles.
>
>
> On Tue, Jun 10, 2008 at 3:42 PM, Christian Grobmeier
> <grobmeier@gmail.com> wrote:
>> Hi all,
>>
>> i want to use Sanselan for extracting EXIF information.
>> This code:
>>
>>  IImageMetadata metadata = Sanselan.getMetadata(jpegFile);
>>  JpegImageMetadata jpgmd = (JpegImageMetadata)metadata;
>>  TiffField field =
>> jpgmd.findEXIFValue(TiffConstants.EXIF_TAG_ORIENTATION);
>>
>> Gives me an out of memor exception, after a second. My image ist  
>> just 150 kb
>> big.
>> Unfortunatly there is no JPEGConstants.EXIF_TAG_ORIENTATION or  
>> similar.
>> Any ideas why that happens?
>>
>> And a second question: how is the state of writing EXIF tags to jpeg?
>> Thanks in advance
>> Chris.
>>
>>
>> Exception in thread "main" java.lang.OutOfMemoryError: Java heap  
>> space
>>   at
>> org 
>> .cmc 
>> .sanselan 
>> .common.byteSources.ByteSourceArray.getBlock(ByteSourceArray.java:51)
>>   at
>> org.cmc.sanselan.formats.tiff.TiffField.fillInValue(TiffField.java: 
>> 356)
>>   at
>> org 
>> .cmc.sanselan.formats.tiff.TiffReader.readDirectory(TiffReader.java: 
>> 164)
>>   at
>> org 
>> .cmc.sanselan.formats.tiff.TiffReader.readDirectory(TiffReader.java: 
>> 105)
>>   at
>> org 
>> .cmc 
>> .sanselan.formats.tiff.TiffReader.readDirectories(TiffReader.java:96)
>>   at org.cmc.sanselan.formats.tiff.TiffReader.read(TiffReader.java: 
>> 416)
>>   at
>> org 
>> .cmc.sanselan.formats.tiff.TiffReader.readContents(TiffReader.java: 
>> 406)
>>   at
>> org 
>> .cmc 
>> .sanselan 
>> .formats.tiff.TiffImageParser.getMetadata(TiffImageParser.java:127)
>>   at org.cmc.sanselan.ImageParser.getMetadata(ImageParser.java:82)
>>   at
>> org 
>> .cmc 
>> .sanselan 
>> .formats.jpeg.JpegImageParser.getExifMetadata(JpegImageParser.java: 
>> 376)
>>   at
>> org 
>> .cmc 
>> .sanselan 
>> .formats.jpeg.JpegImageParser.getMetadata(JpegImageParser.java:314)
>>   at org.cmc.sanselan.Sanselan.getMetadata(Sanselan.java:697)
>>   at org.cmc.sanselan.Sanselan.getMetadata(Sanselan.java:689)
>>   at org.cmc.sanselan.Sanselan.getMetadata(Sanselan.java:667)
>>   at de.grobmeier.imgtools.Rotator.main(Rotator.java:74)
>>

Craig Russell
Architect, Sun Java Enterprise System http://java.sun.com/products/jdo
408 276-5638 mailto:Craig.Russell@sun.com
P.S. A good JDO? O, Gasp!


Mime
View raw message