<div class="gmail_quote"><div>There is no example of vtkMarchingSquares on the wiki - it would be great if you could add one once you get this working!</div><br class="Apple-interchange-newline"><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
this part is wrong viewer-&gt;SetInput(contour-&gt;GetOutput() );  why what I have<br>
to put instead??<br>
 can not convert parameter 1 from &#39;vtkPolyData *&#39; to &#39;vtkImageData *&#39;<br></blockquote><div><br></div><div><br></div><div>That error means that you have read the file as a vtkPolyData, but the filter is expecting a vtkImageData. It doesn&#39;t generally make sense to convert a vtkPolyData (unstructured points and polygons) to a vtkImageData (a grid of values). I&#39;m not sure what you&#39;re doing to read the file, but you might try something like this:</div>
<div><br></div><div><a href="http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/ReadDICOM">http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/ReadDICOM</a>
</div><div><br></div><div>David</div></div>