[Dcmlib] Re: FW: failed to read some DICOM files
Mathieu Malaterre
mathieu.malaterre at kitware.com
Tue May 17 18:40:23 CEST 2005
Dennis,
Ok even gdcm CVS is seg faulting:
$ ./bin/PrintFile /tmp/test.dcm
V 0002|0002[UI] [Media Stored SOP Class UID]
[gdcm::NotLoaded Address:8 Length:1722709 x(1a4955)] ==> [gdcm::Unfound]
--- Pixel information -------------------------
Pixel Data: offset 1701986592 x(65724120) length 808847969 x(30360a61)
----------------- RLE frames --------------------------------
zsh: 10544 segmentation fault ./bin/PrintFile /tmp/test.dcm
Thank you very much for the dataset,
Mathieu
Dennis wrote:
> Actually,this is the first email with attached a sample dicom file for
> this problem. but it was too big to be accepted by "Dcmlib".
>
> thx,
>
> Dennis
>
> ------------------------------------------------------------------------
> *From:* Dennis [mailto:hudr at hotmail.com]
> *Sent:* Wednesday, May 04, 2005 12:24 PM
> *To:* dcmlib at creatis.insa-lyon.fr
> *Subject:* failed to read some DICOM files
>
> Hi,
>
> I tried to use GDCM to read some DICOM files, but i can't read it
> because gdcm::File::IsReadable is false.
> However I tried to read it with the other tools such as IrfanView,
> it can be read correctly. (this file is attached)
> From my debugging, I found something is suspicious :
> In gdcmDocument there is a judge statement in function
> Document::FindDocEntryLength( DocEntry *entry ):
>
> *if ( Filetype == ExplicitVR && !entry->IsImplicitVR() )*
>
> For this DICOM file, Filetype is ACR, entry->IsImplicitVR() is true, VR
> is "UI". so this "if" is false, and then goes to ReadInt32().
> ReadInt32() will return a big number that is not correct. Actually it
> should read ReadInt16.
> From my point of view, if ( Filetype == ExplicitVR &&
> !entry->IsImplicitVR() ) is too strict. As i read from Dicom2004_Part5,
> ps3.5-7.1.2
> , I think if entry is ExplicitVR and VR is UI, Value Length Field is a
> 16-bit unsigned integer.
> I'm not sure if i'm correct because I don't know what is the standard
> format for ACR.
>
> any hints will be helpful,
>
> Thx,
>
> Dennis
>
>
>
>
>
>
More information about the Dcmlib
mailing list