Mesh instancing (kinda)[ANSWERED]

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
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Mesh instancing (kinda)[ANSWERED]

Post by christianclavet »

Hi, Just a question about IRRlicht.

Suppose I have an object: "tunnel.b3d"

I want to re-use 10 times in my level.

How will this mesh stored in memory (mesh cache)?
As 10 copies or only 1 (because mesh filename is the same)?
Last edited by christianclavet on Tue Aug 05, 2008 11:01 pm, edited 1 time in total.
CuteAlien
Admin
Posts: 9736
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Post by CuteAlien »

MeshCache was the right guess :-) It's loaded once and then the same mesh is used in all the nodes. So it's only once in main memory.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
christianclavet
Posts: 1638
Joined: Mon Apr 30, 2007 3:24 am
Location: Montreal, CANADA
Contact:

Post by christianclavet »

Thanks! I was not totally sure.

OK. So I will have to rename the mesh if something is different from it (texture, UV coordinates (because I could use Gile[s] to create Lightmaps)
Icare
Posts: 14
Joined: Tue Jun 24, 2008 3:44 am

Post by Icare »

Or you can just clear the cache and reload the mesh.
Post Reply