MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / UpdateTriangles

Function UpdateTriangles

Source/Engine/Graphics/Models/MeshBase.cpp:27–37  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

25#if !COMPILE_WITHOUT_CSHARP
26 template<typename IndexType>
27 bool UpdateTriangles(MeshBase* mesh, int32 triangleCount, const MArray* trianglesObj)
28 {
29 const auto model = mesh->GetModelBase();
30 ASSERT(model && model->IsVirtual() && trianglesObj);
31
32 // Get buffer data
33 ASSERT(MCore::Array::GetLength(trianglesObj) / 3 >= triangleCount);
34 auto ib = MCore::Array::GetAddress<IndexType>(trianglesObj);
35
36 return mesh->UpdateTriangles(triangleCount, ib);
37 }
38#endif
39}
40

Callers

nothing calls this directly

Calls 3

IsVirtualMethod · 0.80
GetLengthFunction · 0.50
UpdateTrianglesMethod · 0.45

Tested by

no test coverage detected