help converting IMesh node to IAnimatedMeshSceneNode node
Posted: Sat Mar 29, 2008 9:51 pm
hi, the title says it all, but I need help on converting a IMesh to a IAnimatedMeshSceneNode. I know its a very nooby question but I need help.
the code i need help with is here:
roommesh_node is a octtree, but since I loaded it from a .irr file, and the 1st parameter of createOctTree() would be wrong since roommesh isn't a AnimatedMeshSceneNode. can any one help me? thanks in advance,
Ken
the code i need help with is here:
Code: Select all
IMesh* roommesh = smgr->getMesh(roommesh_name.c_str())->getMesh(0);
ITriangleSelector* field1_selector = smgr->createOctTreeTriangleSelector( roommesh,roommesh_node,128);
roommesh_node->setTriangleSelector(field1_selector);
field1_selector->drop();
Ken