Large maulti-frame images wreak havoc

All other questions regarding DCMTK

Moderator: Moderator Team

Post Reply
Message
Author
landishi
Posts: 1
Joined: Thu, 2007-02-08, 04:33

Large maulti-frame images wreak havoc

#1 Post by landishi »

I have used DCMTK 3.5.2 for a long time in our PACS/RIS system and everything worked ok until recently one or our client start getting large multiframe UID_XRayAngiographicImageStorage images. It does not matter if I handle exceptions or not, my ISAPI DLL gets into a unpredictable state after I try to compress images to JPEGProcess14 or rescale them down to create small thumbnails using DicomImage class.
I get an exception with last error 8 - not enough memory and after that it stucks inside one of deregister codec functions and does not move further.
Then the whole DLL stops responding. Do you have any idea what might be causing this. Image that causes this is 352MB in size. i understand that more RAM is needed, I am just trying gracefully recover from this error.
Sincerely,
landishi

Marco Eichelberg
OFFIS DICOM Team
OFFIS DICOM Team
Posts: 1459
Joined: Tue, 2004-11-02, 17:22
Location: Oldenburg, Germany
Contact:

#2 Post by Marco Eichelberg »

You should probably try using DCMTK 3.5.4 or alternatively try to use the non-throwing new operator "new (std::nothrow)" in the following methods:

Code: Select all

DcmByteString::newValueField()
DcmElement::newValueField()
Then check if this allows your code to gracefully exit if decompression fails due to memory requirements.

Post Reply

Who is online

Users browsing this forum: Google [Bot], Semrush [Bot] and 1 guest