<div dir="ltr"><div style="font-size:12.8px">Hi,</div><div style="font-size:12.8px">I am having some troubles with the normal computation of an object.</div><div style="font-size:12.8px"><span style="font-size:12.8px">I am using vtk 7.0.0 and C++ code.</span><br></div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">More precisely, the list of operation I am doing from an stl input  is:</div><div style="font-size:12.8px">1) reading the STL file with vtkSTLReader;</div><div style="font-size:12.8px">2) computing the normals with vtkPolyDataNormals;</div><div style="font-size:12.8px">3) applying a vtkThreshold filter on cell which have a z normal component lower than a given value;</div><div style="font-size:12.8px">4) applying a vtkConnectivityFilter to put together the regions which are connected;</div><div style="font-size:12.8px">5) for each of such regions, applying a linear extrusion with vtkLinearExtrusionFilter</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">   vtkSmartPointer<vtkLinearExtrusionFilter> extrude = vtkSmartPointer<vtkLinearExtrusionFilter>::New();</div><div style="font-size:12.8px">   extrude->SetInputData(geometryFilterInn->GetOutput());</div><div style="font-size:12.8px">   extrude->SetVector(0, 0, -1);</div><div style="font-size:12.8px">   extrude->CappingOn();</div><div style="font-size:12.8px">   extrude->SetScaleFactor(extrusionLength);</div><div style="font-size:12.8px">   extrude->Update();</div><div style="font-size:12.8px">   </div><div style="font-size:12.8px">   being <span style="font-size:12.8px">geometryFilterInn</span><span style="font-size:12.8px"> t</span><span style="font-size:12.8px">he output of point 4).</span></div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">6) exporting the output of linear extrusion filter to stl files with vtkSTLWriter.</div><div style="font-size:12.8px">   </div><div style="font-size:12.8px">You can find two files generated in this way here</div><div style="font-size:12.8px"><div style="font-size:12.8px"><a href="https://app.box.com/s/wkiougfwwxga6vc4rmtyjz25fm1eu9du">https://app.box.com/s/wkiougfwwxga6vc4rmtyjz25fm1eu9du</a></div><div style="font-size:12.8px"><a href="https://app.box.com/s/lvzcu3uvk363ycddcsyd838yccyt2sqq">https://app.box.com/s/lvzcu3uvk363ycddcsyd838yccyt2sqq</a></div></div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">If I calculate the cell normals for such object, I obtain some wrong results (with Paraview 5.0.1 version as well), especially for cells which are connected to the rest of cells only by a vertex and for cells which define a "hole" inside the connected region (for instance, an empty parallelepiped). At present the code I use to compute the normals is the following </div><div style="font-size:12.8px">   </div><div style="font-size:12.8px">       vtkSmartPointer<vtkPolyDataNormals> computeNormals = vtkSmartPointer<vtkPolyDataNormals>::New();</div><div style="font-size:12.8px">       computeNormals->SetInputData(polyDataPtr);</div><div style="font-size:12.8px">       computeNormals->ComputeCellNormalsOn();</div><div style="font-size:12.8px">       computeNormals->Update();</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px"><div style="font-size:12.8px">I've also <span style="font-size:12.8px">unsuccessfully tried</span><span style="font-size:12.8px"> to play with </span></div><div style="font-size:12.8px">computeNormals->ConsistencyOn();</div><div style="font-size:12.8px">computeNormals->AutoOrientNormalsOn();</div><div style="font-size:12.8px"><br></div></div><div style="font-size:12.8px">So, I wonder:</div><div style="font-size:12.8px">1) is it possible to compute the normals for objects which have "holes" and with cells connected to the other cells only by vertex?</div><div style="font-size:12.8px">2) am I doing something wrong with the linear extrusion filter?</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px"><span style="font-size:12.8px">Thank you very much,</span><br></div><div style="font-size:12.8px"><span style="font-size:12.8px"><br></span></div><div style="font-size:12.8px"><span style="font-size:12.8px">Nicolas</span></div></div>