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

Function TEST

source/MRTest/MRExampleTest.cpp:12–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

10{
11
12TEST( MRMesh, BasicExample )
13{
14 // please update MeshLib/doxygen/HowToExamples.dox according to this file
15
16 // load mesh
17 MR::Mesh mesh = MR::makeTorus();
18
19 // relax mesh (5 iterations)
20 MR::relax( mesh, { {5} } );
21
22 // subdivide mesh
23 MR::SubdivideSettings props;
24 props.maxDeviationAfterFlip = 0.5f;
25 MR::subdivideMesh( mesh, props );
26
27 // rotate mesh
28 MR::AffineXf3f rotationXf = MR::AffineXf3f::linear( MR::Matrix3f::rotation( MR::Vector3f::plusZ(), MR::PI_F * 0.5f ) );
29 mesh.transform( rotationXf );
30}
31
32TEST( MRMesh, PrimitivesExtractionExapmle )
33{

Callers

nothing calls this directly

Calls 8

makeTorusFunction · 0.85
subdivideMeshFunction · 0.85
makeCubeFunction · 0.85
getAllTriVertsMethod · 0.80
relaxFunction · 0.50
transformMethod · 0.45
dataMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected