Hi,<br><br>I&#39;m using vtkImageThreshold to segment an image and to generate vtkContourFilter to generate the vtkPolyData, but the resolution of vtkPolyData not getting good by comparison when it is used only the vtkContourFilter to generate vtkPolyData (attached screens).<br>

<br><b>Part of the code vtkImageThreshold and vtkContourFilter</b><br><br>t = vtk.vtkImageThreshold()<br>t.SetInput(reader.GetOutput())<br>t.ThresholdBetween(226,3021)<br>t.SetOutValue(-1024)<br>t.Update()<br><br>contour = vtk.vtkContourFilter()<br>

contour.SetInput(t.GetOutput())<br>contour.SetValue(0, 226) # Initial threshold<br>contour.SetValue(1, 3021) # final threshold<br>contour.ComputeScalarsOn()<br>contour.ComputeGradientsOn()<br><br><img title="vtkImageThreshold.PNG" alt="vtkImageThreshold.PNG" src="cid:ii_12a1953b02539cfc"><br>

<br><b><br><br><br><br>Part of the code only vtkContourFilter</b><br><br>contour = vtk.vtkContourFilter()<br>contour.SetInput(reader.GetOutput())<br>contour.SetValue(0, 226) # Initial threshold<br>contour.SetValue(1, 3021) # final threshold<br>

contour.ComputeScalarsOn()<br>contour.ComputeGradientsOn()<br><br><br><img title="vtkContourFilter.PNG" alt="vtkContourFilter.PNG" src="cid:ii_12a1954134e99d5b"><br><br><br><br>Is it possible to use the vtkImageThreshold and vtkContourFilter but the end result be equal to use only vtkContourFilter to generate polydata ??<br>

<br><br><br>Regards,<br>Paulo Amorim<br><br><br><br>