Now I have two major issues I ran into when attempting to fix this:
I wrote a little function that walks through all meshbuffers of a given animated mesh, inspects all vertices in there and recalculates all normals completely from scratch. That works fine and gives acceptable results if I use it on my scenenode->getMesh()'s mesh.

Code: Select all
if (manager->getMeshCache()->isMeshLoaded(meshpath) == false) {
//mesh is new, fix normals for it:
mesh = manager->getMesh(meshpath);
if (mesh && strendswith(meshpath, ".b3d")) {
//fix the normals!
recalculatesmoothnormals((SAnimatedMesh*)mesh);
}
}else{
//mesh is already present and fixed:
mesh = manager->getMesh(meshpath);
}
Sadly this didn't work. When I created any scene nodes from that mesh, they would have totally ruined normals again.
Update: Fixed this now by using setDirty() for the meshbuffer which I previously didn't by mistake - it doesn't fix the second issue though:

This problem is pretty visible and not just a performance issue, rather trashing all model's normals when animated since I can either have them all borked or not adjusted during animation (which results in them also being borked for complex animations).
Does anyone have an idea what I could do about those two problems (especially the latter one)?