MCPcopy Create free account
hub / github.com/MeshInspector/MeshLib / same

Function same

source/MRMesh/MRMeshTriPoint.cpp:96–116  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

94}
95
96bool same( const MeshTopology & topology, const MeshTriPoint& lhs, const MeshTriPoint & rhs )
97{
98 if ( !lhs )
99 return !rhs;
100 if ( auto le = lhs.onEdge( topology ) )
101 return same( topology, le, rhs.onEdge( topology ) );
102
103 assert ( topology.left( lhs.e ) );
104 if ( topology.left( lhs.e ) != topology.left( rhs.e ) )
105 return false;
106
107 if ( lhs == rhs )
108 return true;
109
110 auto r = rhs.lnext( topology );
111 if ( lhs == r )
112 return true;
113
114 r = r.lnext( topology );
115 return lhs == r;
116}
117
118MeshTriPoint getVertexAsMeshTriPoint( const MeshTopology & topology, EdgeId e, VertId v )
119{

Callers

nothing calls this directly

Calls 3

leftMethod · 0.80
onEdgeMethod · 0.45
lnextMethod · 0.45

Tested by

no test coverage detected