Performance: use merge but still controll individual items?

Software: Away3D 4.x

3dNewb, Sr. Member
Posted: 29 May 2014 11:46 AM   Total Posts: 105

I understand that using Merge “combines” geometry into one big object that you can send to the GPU.

But Is it “enough” if I have Meshes that all use the same Geometry instance? Like this:

var g:CubeGeometry = new CubeGeometry(..)
var mesh1:Mesh = new Mesh(g);
var mesh2:Mesh = new Mesh(g);
...
var mesh20000:Mesh = new Mesh(g);

is this the most optimized way of doing this? I do want to be able to re-position the individual meshes.

Should I still merge above example?

   

Mr Margaret Scratcher, Sr. Member
Posted: 05 June 2014 12:08 AM   Total Posts: 344   [ # 1 ]

You’ll save memory by re-using geometry, but merging them reduces the amount of draw calls (I think…)

So yes, ideally merging will improve performance - 100,000 planes will see framrate drop, but a mesh made of 100,000 plane will be fine.

There is a thread somewhere on here where someone was trying to make a minecraft style engine, which had some interesting information about merging cubes, but then translating their vertices individually in order to reposition each cube.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X