[Dcmlib] force loading elements

Mathieu Malaterre mathieu.malaterre at kitware.com
Tue Aug 30 00:34:19 CEST 2005


Jean-Pierre Roux wrote:
> Hi!
> 
> According to some users requirement, we can now force the loading of 
> some elements whose length exceeds the current MAX_SIZE_LOAD_ELEMENT_VALUE.
> 
> use it as :
>      gdcm::File *f = new gdcm::File();
>      f->SetLoadMode(loadMode);
>      f->SetFileName( fileName );
>      f->AddForceLoadElement(0x0029,0x1010);
>      f->AddForceLoadElement(0x0028,0x1020);
>      bool res = f->Load();
> 
> Check it with :
> 
> PrintFile filein=wereInGdcmData/MR_forceLoad29-1010_29-1020.dcm  
> forceload=29-1010,29-1020


Really neat !

	Just for background information, gdcm has a default behavior of 
skeeping reading the long binary stream. So far this was ok because user 
are only interested in the DICOM image. But the /famous/ 0029, 1010 
Siemens tag is actually needed when you start doing any thing fancy. 
Indeed the so called /Siemens addendum/ contain lot of information that 
allow proper reconstruction of the DICOM volume.

Mathieu
For more info, on this private tag:

original report:
<...>
Thanks for your help. I will give your suggestion a try.This field as
actually an ASCII parameter map for the Siemens pulse sequence used to
create the images. It provides all information allowing you to take an
image from one Siemens scanner to another scanner and completely specify
the imaging parameters. An example of some of the fields are shown at
this site:

http://www.enac.northwestern.edu/~tew/archives/2003/02/25/incomplete-dicom-headers/


Since information about the DTI study such as number of directions and
number of b values applied are stored in this header, it will allow me
to convert the 3D data to a 4D representation that we use to analyze the
data.
<...>



More information about the Dcmlib mailing list