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

Method loopDirArea

source/MRMesh/MRPolyline.cpp:168–181  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

166
167template<typename V>
168Vector3f MR::Polyline<V>::loopDirArea( EdgeId e0 ) const
169{
170 Vector3f area;
171 auto e = e0;
172 for ( ;; )
173 {
174 area += cross( Vector3f( orgPnt( e ) ), Vector3f( destPnt( e ) ) );
175 e = topology.next( e.sym() );
176 if ( e == e0 )
177 return area;
178 else if ( e == e0.sym() )
179 return Vector3f( 0.0f, 0.0f, FLT_MAX );
180 }
181}
182
183template<typename V>
184float Polyline<V>::totalLength() const

Callers 1

TESTFunction · 0.80

Calls 5

orgPntFunction · 0.85
destPntFunction · 0.85
crossFunction · 0.70
nextMethod · 0.45
symMethod · 0.45

Tested by 1

TESTFunction · 0.64