[Insight-users] Convert dicom image to other format

Frank Zhao zhaofrank at hotmail.com
Tue Jun 22 14:55:50 EDT 2004


The volume type is:

  typedef signed short   PixelType;
  typedef itk::Image< PixelType, 3 >                VolumeType;

The DICOM files is CT image data.

I use both snap and volview to view the result MetaImage file.

Accurely, it is not corrupted, it still show as a 3D image, but like a biany 
image of the original one, I check the voxel value, it is not biniary image. 
with some voxel value goes up to 60000 and some only around 50, look like a 
bianary image.

I modified the ISIS demo source for DICOM files( project name: 
APPLICATIONMODEL, following the cvs download provided by you), it displays 
DICOM image correctly, I only  add the writer code after DICOM image is 
loaded.

When DICOM is readed, it uses signed short as the image type.

Thank you Luis

Frank

>From: Luis Ibanez <luis.ibanez at kitware.com>
>To: Frank Zhao <zhaofrank at hotmail.com>
>CC: insight-users at itk.org
>Subject: Re: [Insight-users] Convert dicom image to other format
>Date: Tue, 22 Jun 2004 14:18:49 -0400
>
>
>Hi Frank,
>
>What is the type:
>
>         "VolumeType"   ?
>
>What is the image modality contained in the
>DICOM files ? (CT, MRI, PET )?
>
>What are you using for viewing the resulting
>MetaImage file ? (and concluding that it is
>corrupted ?).
>
>
>It is very likely that you are using an
>inappropriate pixel type for reading your
>DICOM images.
>
>For example, trying to read 16 bits into an
>image type of 8 bits...
>
>
>
>Regards,
>
>
>    Luis
>
>
>--------------------
>Frank Zhao wrote:
>
>>
>>  After I load 3d Dicom image series, it displays correctly. The image is 
>>corrupted when I using following code to convert it into another format. 
>>But it convert correctly when I load a 3D gipl file.
>>
>>What is the reason?
>>
>>Thank you
>>
>>Frank
>>
>>=========================================
>>  typedef itk::ImageFileWriter< VolumeType > WriterType;
>>  WriterType::Pointer writer = WriterType::New();
>>  writer->SetFileName( "c:\\temp\\test_write.mhd" );
>>  writer->SetInput( m_Reader->GetOutput() );
>>  writer->Update();
>>
>>_________________________________________________________________
>>Is your PC infected? Get a FREE online computer virus scan from 
>>McAfee?Security. 
>>http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963
>>
>>_______________________________________________
>>Insight-users mailing list
>>Insight-users at itk.org
>>http://www.itk.org/mailman/listinfo/insight-users
>>
>
>
>

_________________________________________________________________
Is your PC infected? Get a FREE online computer virus scan from McAfee® 
Security. http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963



More information about the Insight-users mailing list