Every topic when talking about optimalisation, ppl recommends to batch those nodes what not moving, etc.
Now i wanted to try it out to see how it increases the performance, but couldnt find how to do it.
this is what i tried:
- Code: Select all
IAnimatedMesh* mesh = ((IAnimatedMeshSceneNode*)newObj->getNode())->getMesh();
batchObj = device->getSceneManager()->addMeshSceneNode(mesh);
for (u32 n = 0; n < mesh->getMeshBufferCount(); n++)
I guess its doing its job right, but the problem it isnt saving the positions (of course coz meshes dont have positions )
So, how could i batch them, and keep my node positions, rotations, scales?