MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / Rebuild

Method Rebuild

src/Mod/Mesh/App/Core/Algorithm.cpp:1896–1910  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1894// ----------------------------------------------------
1895
1896void MeshRefPointToFacets::Rebuild()
1897{
1898 _map.clear();
1899
1900 const MeshPointArray& rPoints = _rclMesh.GetPoints();
1901 const MeshFacetArray& rFacets = _rclMesh.GetFacets();
1902 _map.resize(rPoints.size());
1903
1904 auto pFBegin = rFacets.begin();
1905 for (auto pFIter = rFacets.begin(); pFIter != rFacets.end(); ++pFIter) {
1906 _map[pFIter->_aulPoints[0]].insert(pFIter - pFBegin);
1907 _map[pFIter->_aulPoints[1]].insert(pFIter - pFBegin);
1908 _map[pFIter->_aulPoints[2]].insert(pFIter - pFBegin);
1909 }
1910}
1911
1912Base::Vector3f MeshRefPointToFacets::GetNormal(PointIndex pos) const
1913{

Callers

nothing calls this directly

Calls 13

DistanceP2Function · 0.85
NormalizeMethod · 0.80
clearMethod · 0.45
GetPointsMethod · 0.45
GetFacetsMethod · 0.45
resizeMethod · 0.45
sizeMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
insertMethod · 0.45
findMethod · 0.45
GetNormalMethod · 0.45

Tested by

no test coverage detected