• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

imageio bug?

 
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys,
i've developed an applet that handles displaying medical images, as well as an image converter application, the images handled are DICOM-JPEG2000 images. All is working fine, yet with some images, i am getting a crash in the jvm. In my code, i am relying on an open source library (dcm4che) to decode the image bytes and return for me a BufferedImage instance, and the reason i am doubting a bug in imageio is that the crash is occuring in the imageio dll (clib_jiio.dll). I also tried displaying the images using dcm4che alone(without integration to my code), as well as another imaging tool (apteryx), and both crashed in the dll.
I have jre and imageio tools installed (i tried imageio 1.0_01 and the newer imageio 1.1-alpha, and they both crashed)
Any suggestions?
Thanks a lot guys,
Mohammad

Here is a full trace of the crash:
An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x393FE15
Function=[Unknown.]
Library=C:\j2sdk1.4.2_08\jre\bin\clib_jiio.dll

NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.


Current Java thread:
at com.sun.medialib.codec.jp2k.Decoder.decode(Native Method)
at com.sun.medialib.codec.jp2k.Decoder.decode(Decoder.java:107)
at com.sun.media.imageioimpl.plugins.jpeg2000.J2KRenderedImageCodecLib.readAsRaster(J2KRenderedImageCodecLib.java:274)
- locked <0x10018a70> (a com.sun.media.imageioimpl.plugins.jpeg2000.J2KRenderedImageCodecLib)
at com.sun.media.imageioimpl.plugins.jpeg2000.J2KImageReaderCodecLib.read(J2KImageReaderCodecLib.java:322)
at org.dcm4cheri.imageio.plugins.DcmImageReader.decompress(DcmImageReader.java:480)
at org.dcm4cheri.imageio.plugins.DcmImageReader.read(DcmImageReader.java:366)
- locked <0x10886c80> (a org.dcm4cheri.imageio.plugins.DcmImageReader)
at javax.imageio.ImageIO.read(ImageIO.java:1384)
at javax.imageio.ImageIO.read(ImageIO.java:1348)
at dicomviewer.ImageData.setDataAndCreateImage(ImageData.java:553)
at dicomviewer.ImageData.setDicomData(ImageData.java:124)
at dicomviewer.DicomFile.load(DicomFile.java:312)
at dicomviewer.Viewer.postData(Viewer.java:385)
- locked <0x1053fa08> (a dicomviewer.Viewer)
at dicomviewer.LoaderThread.run(LoaderThread.java:54)

Dynamic libraries:
0x00400000 - 0x0040B000 C:\j2sdk1.4.2_08\bin\javaw.exe
0x77CC0000 - 0x77D75000 C:\WINDOWS\system32\ntdll.dll
0x77E60000 - 0x77F50000 C:\WINDOWS\system32\kernel32.dll
0x77F50000 - 0x77FEB000 C:\WINDOWS\system32\ADVAPI32.dll
0x77340000 - 0x773D1000 C:\WINDOWS\system32\RPCRT4.dll
0x77D80000 - 0x77E11000 C:\WINDOWS\system32\USER32.dll
0x773E0000 - 0x77425000 C:\WINDOWS\system32\GDI32.dll
0x77C10000 - 0x77C68000 C:\WINDOWS\system32\MSVCRT.dll
0x629C0000 - 0x629C9000 C:\WINDOWS\system32\LPK.DLL
0x74770000 - 0x747DB000 C:\WINDOWS\system32\USP10.dll
0x08000000 - 0x08138000 C:\j2sdk1.4.2_08\jre\bin\client\jvm.dll
0x76B40000 - 0x76B6D000 C:\WINDOWS\system32\WINMM.dll
0x10000000 - 0x10007000 C:\j2sdk1.4.2_08\jre\bin\hpi.dll
0x00830000 - 0x0083E000 C:\j2sdk1.4.2_08\jre\bin\verify.dll
0x00840000 - 0x00859000 C:\j2sdk1.4.2_08\jre\bin\java.dll
0x00860000 - 0x0086E000 C:\j2sdk1.4.2_08\jre\bin\zip.dll
0x02C60000 - 0x02D72000 C:\j2sdk1.4.2_08\jre\bin\awt.dll
0x73000000 - 0x73026000 C:\WINDOWS\system32\WINSPOOL.DRV
0x76390000 - 0x763AD000 C:\WINDOWS\system32\IMM32.dll
0x774D0000 - 0x7760D000 C:\WINDOWS\system32\ole32.dll
0x5AD70000 - 0x5ADA7000 C:\WINDOWS\system32\uxtheme.dll
0x033F0000 - 0x03441000 C:\j2sdk1.4.2_08\jre\bin\fontmanager.dll
0x73760000 - 0x737A9000 C:\WINDOWS\system32\ddraw.dll
0x73BC0000 - 0x73BC6000 C:\WINDOWS\system32\DCIMAN32.dll
0x73940000 - 0x73A10000 C:\WINDOWS\system32\D3DIM700.DLL
0x74720000 - 0x7476B000 C:\WINDOWS\system32\MSCTF.dll
0x605D0000 - 0x605D9000 C:\WINDOWS\system32\mslbui.dll
0x037A0000 - 0x037C3000 C:\j2sdk1.4.2_08\jre\bin\cmm.dll
0x038D0000 - 0x038EE000 C:\j2sdk1.4.2_08\jre\bin\jpeg.dll
0x038F0000 - 0x039DD000 C:\j2sdk1.4.2_08\jre\bin\clib_jiio.dll
0x03750000 - 0x0375F000 C:\j2sdk1.4.2_08\jre\bin\net.dll
0x71AB0000 - 0x71AC7000 C:\WINDOWS\system32\WS2_32.dll
0x71AA0000 - 0x71AA8000 C:\WINDOWS\system32\WS2HELP.dll
0x71A50000 - 0x71A8E000 C:\WINDOWS\System32\mswsock.dll
0x76F20000 - 0x76F47000 C:\WINDOWS\system32\DNSAPI.dll
0x76FB0000 - 0x76FB7000 C:\WINDOWS\System32\winrnr.dll
0x76F60000 - 0x76F8D000 C:\WINDOWS\system32\WLDAP32.dll
0x76FC0000 - 0x76FC5000 C:\WINDOWS\system32\rasadhlp.dll
0x662B0000 - 0x66304000 C:\WINDOWS\system32\hnetcfg.dll
0x76B20000 - 0x76B3D000 C:\WINDOWS\system32\ATL.DLL
0x77120000 - 0x771AC000 C:\WINDOWS\system32\OLEAUT32.dll
0x76EE0000 - 0x76F1C000 C:\WINDOWS\system32\RASAPI32.dll
0x76E90000 - 0x76EA2000 C:\WINDOWS\system32\rasman.dll
0x5FE20000 - 0x5FE73000 C:\WINDOWS\system32\NETAPI32.dll
0x76EB0000 - 0x76EDF000 C:\WINDOWS\system32\TAPI32.dll
0x772D0000 - 0x7731E000 C:\WINDOWS\system32\SHLWAPI.dll
0x76E80000 - 0x76E8E000 C:\WINDOWS\system32\rtutils.dll
0x76400000 - 0x765A0000 C:\WINDOWS\system32\netshell.dll
0x76C00000 - 0x76C2E000 C:\WINDOWS\system32\credui.dll
0x7C800000 - 0x7D010000 C:\WINDOWS\system32\SHELL32.dll
0x76D60000 - 0x76D79000 C:\WINDOWS\system32\iphlpapi.dll
0x76BF0000 - 0x76BFB000 C:\WINDOWS\system32\PSAPI.DLL
0x76D80000 - 0x76D9D000 C:\WINDOWS\system32\DHCPCSVC.DLL
0x77E20000 - 0x77E31000 C:\WINDOWS\system32\Secur32.dll
0x4D6C0000 - 0x4D7AC000 C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.2096_x-ww_a7d210bd\comctl32.dll
0x77430000 - 0x774CA000 C:\WINDOWS\system32\comctl32.dll
0x71A90000 - 0x71A98000 C:\WINDOWS\System32\wshtcpip.dll
0x76C90000 - 0x76CB8000 C:\WINDOWS\system32\imagehlp.dll
0x5D090000 - 0x5D131000 C:\WINDOWS\system32\DBGHELP.dll
0x77C00000 - 0x77C08000 C:\WINDOWS\system32\VERSION.dll

Heap at VM Abort:
Heap
def new generation total 640K, used 611K [0x10010000, 0x100c0000, 0x104f0000)
eden space 576K, 98% used [0x10010000, 0x1009def8, 0x100a0000)
from space 64K, 68% used [0x100a0000, 0x100aae38, 0x100b0000)
to space 64K, 0% used [0x100b0000, 0x100b0000, 0x100c0000)
tenured generation total 8104K, used 5236K [0x104f0000, 0x10cda000, 0x14010000)
the space 8104K, 64% used [0x104f0000, 0x10a0d0e8, 0x10a0d200, 0x10cda000)
compacting perm gen total 7168K, used 6935K [0x14010000, 0x14710000, 0x18010000)
the space 7168K, 96% used [0x14010000, 0x146d5e70, 0x146d6000, 0x14710000)

Local Time = Wed Dec 28 14:51:49 2005
Elapsed Time = 17
#
# The exception above was detected in native code outside the VM
#
# Java VM: Java HotSpot(TM) Client VM (1.4.2_08-b03 mixed mode)
#
# An error report file has been saved as hs_err_pid3204.log.
# Please refer to the file for further information.
#
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Have you gotten this code to work in a desktop application? I'm wondering if this isn't more of an applet/Java plugin/browser problem than an ImageIO problem.
 
Mohammad Farhat
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Well, i don't quite understand what you mean by that, but one thing i know is that my applet is signed, besides, most of the images are displaying properly, so why on some images it would crash if it wasn't for some bug in ImageIO?
Thanks a lot Ulf for all your replies
Best,
Mohammad
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If I understand well, I am prone to belive that the type of dicom jpeg 2000 images ( allways a little bit tricky) have some kind of problem to process the diferent tasks of compression and decompression.

There are an article complaining exactly about the limitations of this java library vis-a-vis the management of j2k images.

I'm telling this because we are facing the similar problems, with our applet which has the same scope of yours.

We have implemented a solutions in C++ - an activex component -- a dicom web viewer. I can send you the code if you like.

Our project used to be a commercial project, but we derived a brach only to deal with open - source code.

So , I ' ll be glad to see your software ( are there any demos ?) and if you agree your sorce code.

Perhaps we both can accelerate the developement of our solutions ?

Let me know about.

Dr Grover MD
Brazil
 
reply
    Bookmark Topic Watch Topic
  • New Topic