function changeMaterial