Material Management
Efficiently manage multiple materials:
// Clone a material
const material2 = material.clone("material2");
material2.diffuseColor = new BABYLON.Color3(0, 1, 0); // Change color to green
// Create material instances (shares resources but allows property overrides)
const materialInstance = material.instantiateForInstance();
materialInstance.diffuseColor = new BABYLON.Color3(0, 0, 1); // Blue variant