Page 1 of 1

How to delete meshes from the SceneManager?

Posted: Mon Mar 28, 2011 5:24 pm
by fabuloes
Hey everybody,

I have a problem to delete a Mesh from the SceneManager, which I have created with addAnimatedSceneNode().
I tried to get the Scene by using getSceneNodeFromId( id ), and then call ->remove(), but it always crashes at this point :(
The id is correct, even as the Scene I get.

I have not very much experience with Irrlicht, and I'm german so don't annoy about bad english ;)

Posted: Mon Mar 28, 2011 5:41 pm
by ChaiRuiPeng
meshes and scene nodes are different things.

do you have a handle on a pointer to the scene node you are trying to remove?

what exactly are you trying to do? do you need to remove the mesh from memory or you don't want to see the scene node (make it invisible)?

Posted: Mon Mar 28, 2011 5:48 pm
by serengeor
as long as the node you 'remove()' is correct it should be fine, I can only guess that you're removing it more than one time i.e: in the main loop.