MeshSplitter: Difference between revisions

From Crumbled World Wiki
(Created page with "{{:MeshSplitterExampleCode}} ==Constructor== {| class="wikitable" !|function !|description |- |MeshSplitter() | |- |} template:func ==Functions== {| class="wikitable" !|return !|function !|description |- |ListSplittedMesh |splitMesh(Mesh meshToSplit) |plit an mesh up into several submeshes. for speed recommend to use soft normals else this function will be very slow. |- | |MeshSplitter:calculateSubMeshMovement...")
 
(No difference)

Latest revision as of 13:00, 5 July 2025

MeshSplitterExampleCode

Constructor

function description
MeshSplitter()

template:func

Functions

return function description
ListSplittedMesh splitMesh(Mesh meshToSplit) plit an mesh up into several submeshes. for speed recommend to use soft normals else this function will be very slow.
calculateSubMeshMovement(float deltaTime) used to calculate movement speed of submeshes this can be used when having an animated mesh there different sub meshes has different speed and direction. to use the mesh need to be updated from the split mesh

EX: meshSplitter.splitMesh(pMesh); pMesh->animationUpdate(Core::_deltaTime); meshSplitter.calculateSubMeshMovement(Core::_deltaTime);

compileSubMeshes() compile the subMesh with new origo.