Memory during mesh reassignments

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
sash
Competition winner
Posts: 35
Joined: Thu Nov 05, 2009 8:46 am
Location: Novosibirsk

Memory during mesh reassignments

Post by sash »

Hello.
Is it ok (regarding to safe memory reallocation) to use code below ?

Code: Select all

  IAnimatedMesh* mesh
  //.....
  IMeshManipulator* mm = SceneManager->getMeshManipulator();
  mesh = mm->createAnimatedMesh( mm->createMeshWith2TCoords(mesh) );
Will it lead to any memory leaks ?
B@z
Posts: 876
Joined: Thu Jan 31, 2008 5:05 pm
Location: Hungary

Post by B@z »

afaik since u create it, u have to drop it when u dont need anymore (after u added it to a scene node)
Image
Image
Post Reply