Bryn <br><br>Thank you for the response. Yes the vtkKWImage can read a DICOM series, let me try the &#39;SetITKImageBase&#39; part which I have not tested. <br><br>Also, the seed picker code is great, that is my next part to code. <br>
<br>Thank you, I will update on the SetITKImageBase<br><br>Sergio <br><br><div class="gmail_quote">On Fri, Mar 20, 2009 at 12:51 AM, Bryn Lloyd <span dir="ltr">&lt;<a href="mailto:blloyd@vision.ee.ethz.ch">blloyd@vision.ee.ethz.ch</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hello Sergio,<br>
<br>
<br>
The vtkKWImage and vtkKWImageIO classes are mainly useful for:<br>
<br>
1. read (nearly) all the image formats that ITK can read using vtkKWImageIO -&gt; returns a vtkKWImage, which has the method &quot;GetVTKImage&quot;.<br>
<br>
2. at the end of an itk pipeline, pass the itk image to the vtkKWImage object using &quot;SetITKImageBase&quot; and get the vtkImageData for your visualization pipeline.<br>
<br>
<br>
If you want to read an image and pass it to an itkImage for image processing, an itkImageReader is more straightforward.<br>
<br>
<br>
BTW: I am not sure if the vtkKWImageIO class can read Dicom images. I would suggest following:<br>
<br>
1. Read dicom images using an itk reader, which can handle dicom<br>
2. pass itkImage to vtkKWImage<br>
3. pass vtkImageData from vtkKWImage to your viewer (e.g. vtkImageViewer2).<br>
<br>
<br>
If you have 3D images and want to move between slices, and if you maybe even want to select pixels (seed points), then you could use my own image viewer.<br>
<br>
<a href="http://www.vision.ee.ethz.ch/%7Eblloyd/ImageViewer/" target="_blank">http://www.vision.ee.ethz.ch/~blloyd/ImageViewer/</a><br>
<br>
bye<br>
Bryn<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
Sergio Aguirre wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div class="h5">
Hello<br>
<br>
I am trying to do a simple 2D Dicom series reader and viewer using ITK and VTK.<br>
<br>
Initially I used the itk GDCM class and successfully read a DICOM series and using the itk-vtk imoprter and exporter classes was able to connect the pipelines so that I would write an XML file (VTI) using vtk classes. Then read the vti file and display it in VTK.<br>

<br>
I would prefer to it without writing the XML file. If I use a different than the vtkXMLwriter class, say vtkImageShifScale or vtkImageViewer2 to catch the DICOM stack I get a segmentation fault.<br>
<br>
Recently I found the vtkKWImage and vtkKWImageIO classes and was successfull at reading the DICOM files and connecting them to both vtk classes I mentioned (shifter and viewer). <a href="http://insight-journal.org/dspace/handle/1926/495" target="_blank">http://insight-journal.org/dspace/handle/1926/495</a><br>

<br>
BUT I don&#39;t know if I could use an itk filter (say itkCurvatureFlowImageFilter) before displaying them since I only found the &quot;Setfilename&quot; and &quot;Setdirectory&quot; options for the vtkKWImage class.<br>

<br>
Can you use vtkKWImage and vtkKWImageIO in combination with itk Filters?<br>
<br>
If not, is there an explanation for the segmentation fault I get when not using the XML writer?<br>
<br>
Thank you,<br>
<br>
Sergio<br>
<br>
<br></div></div>
------------------------------------------------------------------------<br>
<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote>
<br>
<br>
-- <br>
-------------------------------------------------<br><font color="#888888">
Bryn Lloyd<br>
Computer Vision Laboratory<br>
ETH Zürich, Sternwartstrasse 7<br>
CH - 8092 Zürich, Switzerland<br>
Tel: +41 44 63 26668<br>
Fax: +41 44 63 21199<br>
-------------------------------------------------<br>
</font></blockquote></div><br>