Hi,<br><br>I'm trying to generate a mesh for export and analysis via finite element. <br><br>But the original mesh are very triangle. <br><br><div style="text-align: left;" id="result_box" dir="ltr">If you apply the filter mesh decimação is a little deformed.<br>
<br><div style="text-align: left;" id="result_box" dir="ltr">The Imagedata is generated from a CT 512x512 with 200 slices.</div><br>
<div style="text-align: left;" id="result_box" dir="ltr">What can I doing wrong ?</div>
<br><br>The Code:<br><br> mcubes = vtk.vtkMarchingCubes()<br> mcubes.GetOutput().ReleaseDataFlagOff()<br> mcubes.SetInput(_imagedata)<br> mcubes.SetValue(0, 4)<br> mcubes.ComputeGradientsOn()<br>
mcubes.Update()<br> <br> smoother = vtk.vtkSmoothPolyDataFilter()<br> smoother.GetOutput().ReleaseDataFlagOff()<br> smoother.SetInput(mcubes.GetOutput())<br> smoother.SetNumberOfIterations(5)<br>
smoother.SetRelaxationFactor(0.70)<br> smoother.SetFeatureAngle(70)<br> smoother.FeatureEdgeSmoothingOn()<br> smoother.BoundarySmoothingOn()<br> smoother.Update()<br> <br> normals = vtk.vtkPolyDataNormals()<br>
normals.GetOutput().ReleaseDataFlagOff()<br> normals.SetInput(smoother.GetOutput())<br> normals.SetFeatureAngle(80)<br> normals.Update()<br> <br> stripper = vtk.vtkStripper()<br>
stripper.SetInput(normals.GetOutput())<br> stripper.GetOutput().ReleaseDataFlagOff()<br> stripper.Update()<br> <br> mesh = normals.GetOutput()<br><br><br><br>Regards<br>Paul Jhin<br></div>