[vtkusers] read dicom series files

Gururajan gururajan.r at raster.in
Wed Jul 29 12:26:21 EDT 2009


Hi,

Thanks for your link, but this is in Python, write, actually i need it
in JAVA, and i almost done with environment setup .
the below code i used to read dicom series and write in .vtk format. the
problem is .vtk file which i written is not opened by vtk.

 vtkDICOMImageReader dicomreader = new vtkDICOMImageReader();
    dicomreader.SetDirectoryName("/home/gururaj/MANIX/MANIX/CER-CT/ANGIO
CT");
    dicomreader.Update();
    System.out.println("File Dimension " + 
dicomreader.GetFileDimensionality());
   
    vtkImageWriter writer = new  vtkImageWriter();//vtkImageWriter::New()
    writer.SetInput(dicomreader.GetOutput());
    //writer.AddInput(dicomreader.GetOutput());
    writer.SetFileName("/home/gururaj/eclipse
Project/SimpleVTK/SimpleVtk/CardiacCT/Ronald.vtk");
    writer.SetFileDimensionality(3);
   
    writer.Update();
    writer.Write();

Thanks
Guru
Charl Botha wrote:
> 2009/7/28 Gururajan <gururajan.r at raster.in>:
>   
>> Hi
>>    Please any one can help me to read dicom series of files and convert
>> into to .vtk format to view in 3d.
>>     
>
> <shameless opensource plug>
>
> If you're interested in getting from DICOM to VTK in the most painless
> and user-friendly way, you could try the open source DeVIDE software.
> See here for the help documentation on the built-in DICOMBrowser:
> http://code.google.com/p/devide/wiki/HelpDICOMBrowser
>
> In short:
> 1. DICOMBrowser to explore your data
> 2. DICOMReader to read the series you want
> 3a. slice3dVWR to slice through it
> 3b. vtiWRT to save the relevant volume as a VTK XML Image Data file.
>
> DeVIDE is based on Python, wxPython, VTK, ITK and GDCM (and DCMTK, and
> a bunch of other things).
>
> </shameless opensource plug>
>
> :)
>   




More information about the vtkusers mailing list