This might be a noob question but I haven’t seen any actual confirmation on this.
Cloning doesn’t save drawcalls like instancing does, so I’m wondering if there’s any real performance benefit, apart from not having to load a model from disk again.
This might be a noob question but I haven’t seen any actual confirmation on this.
Cloning doesn’t save drawcalls like instancing does, so I’m wondering if there’s any real performance benefit, apart from not having to load a model from disk again.
The cloning does create a new mesh, actually:
public clone(name: string = "", newParent: Nullable<Node> = null,
doNotCloneChildren?: boolean, clonePhysicsImpostor: boolean = true): Mesh {
return new Mesh(name, this.getScene(), newParent, this, doNotCloneChildren,
clonePhysicsImpostor);
}
The performance gain is a memory one: the geometry is shared between the source mesh and the clone(s).
Ah right! Thanks for clearing that up.