Can you get the mesh from the scene node?

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
uzik
Posts: 24
Joined: Wed Sep 22, 2004 4:56 pm

Can you get the mesh from the scene node?

Post by uzik »

Good afternoon all:

I've loaded a mesh and animated it by applying rotations to the scene
node:

IAnimatedMeshSceneNode* node; // animated mesh
node->setRotation(r); //rotate node

I can get to the original unrotated IMesh with:
IAnimatedMesh* mesh;
mesh->getMesh( node->getFrameNr() )

Any way to get to the rotated IMesh?

Thanks![/b]
Tyn
Posts: 932
Joined: Thu Nov 20, 2003 7:53 pm
Location: England
Contact:

Post by Tyn »

The rotations are stored in the scene node aren't they?
uzik
Posts: 24
Joined: Wed Sep 22, 2004 4:56 pm

Post by uzik »

the current relative rotation is stored there,
but I was trying to get to the rotated mesh polygons.

It looks like when you attach a mesh to a node it makes
a copy of it and manipulates the copy. I guess it's
storing the current mesh and applying transformations
to that after each rendering pass. It names the
rotation amount variable with 'relative' in the name.
Post Reply