Segmented Contours from 3d imagedata

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Segmented Contours from 3d imagedata

zmanvortex
I am using vtkContourFilter with 3D vtkImageData (unsigned char scalars) as it's input. I am able to get the pipeline to work, but I am wondering if I can define the distance the filter uses to segment surfaces with the same scalar value. It appears the filter is creating a single surface for a given contour value instead of multiple surfaces when they are far apart.

Screenshot of the image data:
ImageData

Screenshot of the front of multiple contours:
Front of contour

Screenshot of the back of multiple contours:
Back of contour
Reply | Threaded
Open this post in threaded view
|

Re: Segmented Contours from 3d imagedata

zmanvortex
After further research it appears using multiple contours with vtkContourFilter does not function the way I originally thought. I assumed if I set a contour value, lets say 80.0, that it would only render surfaces with that scalar value from the image data. It appears that it renders surfaces for any scalar value equal to or above 80.0. With my scalar range from 0 to 254.0 it means that a surface is created from scalars of between 80.0 to 254.0 inclusive. Is there another filter that will render an isosurface for a discrete scalar value?

I have tried vtkDiscreteMarchingCubes but it doesn't give the results I intended. Here is a screenshot:
DiscreteMarchingCubes