1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
/**
* Materials that can be used for the robots.
*/
public enum Material {
/**
* Gold material properties.
* Modify the default values to make it look like gold.
*/
GOLD (
new float[] {0.8f, 0.8f, 0.8f, 1.0f},
new float[] {0.0f, 0.0f, 0.0f, 1.0f}),
/**
* Silver material properties.
* Modify the default values to make it look like silver.
*/
SILVER (
new float[] {0.8f, 0.8f, 0.8f, 1.0f},
new float[] {0.0f, 0.0f, 0.0f, 1.0f}),
/**
* Wood material properties.
* Modify the default values to make it look like wood.
*/
WOOD (
new float[] {0.8f, 0.8f, 0.8f, 1.0f},
new float[] {0.0f, 0.0f, 0.0f, 1.0f}),
/**
* Orange material properties.
* Modify the default values to make it look like orange.
*/
ORANGE (
new float[] {0.8f, 0.8f, 0.8f, 1.0f},
new float[] {0.0f, 0.0f, 0.0f, 1.0f});
/** The diffuse RGBA reflectance of the material. */
float[] diffuse;
/** The specular RGBA reflectance of the material. */
float[] specular;
/**
* Constructs a new material with diffuse and specular properties.
*/
private Material(float[] diffuse, float[] specular) {
this.diffuse = diffuse;
this.specular = specular;
}
}
|