1 /**
  2  * potree.js 
  3  * http://potree.org
  4  *
  5  * Copyright 2012, Markus Sch�tz
  6  * Licensed under the GPL Version 2 or later.
  7  * - http://potree.org/wp/?page_id=7
  8  * - http://www.gnu.org/licenses/gpl-3.0.html
  9  *
 10  */
 11 
 12 /**
 13  * 
 14  * @param {String} name a unique name for the material or null. If name is null, a unique name will be generated.  
 15  * @class The base class for all materials.
 16  * @author Markus Sch�tz
 17  */
 18 function Material(name){
 19 	if (arguments[0] === inheriting) return;
 20 	
 21 	if(name == null){
 22 		name = "Material_" + Material.count;
 23 	}
 24 	this.name = name;
 25 	
 26 	MaterialManager.addMaterial(this);
 27 	
 28 	Material.count++;
 29 }
 30 
 31 Material.count = 0;