10.2 - Surface Colors

Light reflects off of an object into a camera which allows us to “see” the object. We have discussed three types of light reflection: ambient, diffuse, and specular reflection. It turns out that each type of reflection interacts with the surface of an object in slightly different ways and using a single color for an object can’t capture the true nature of these different types of reflection.

Researchers took various types of physical objects and precisely measured light reflection for ambient, diffuse, and specular reflection. Some of their results are listed below. Instead of storing a single color for a surface, you can store a specific color for each type of light reflection. This provides more realistic visual results. In your fragment shader calculations you would use the appropriate color for each type of light reflection.

Examples of Object Colors [1]

Material Ambient color Diffuse color Specular color Shininess
Brass
0.329412
0.223529
0.027451
1.0
0.780392
0.568627
0.113725
1.0
0.992157
0.941176
0.807843
1.0
27.8974
Bronze
0.2125
0.1275
0.054
1.0
0.714
0.4284
0.18144
1.0
0.393548
0.271906
0.166721
1.0
25.6
Polished Bronze
0.25
0.148
0.06475
1.0
0.4
0.2368
0.1036
1.0
0.774597
0.458561
0.200621
1.0
76.8
Chrome
0.25
0.25
0.25
1.0
0.4
0.4
0.4
1.0
0.774597
0.774597
0.774597
1.0
76.8
Copper
0.19125
0.0735
0.0225
1.0
0.7038
0.27048
0.0828
1.0
0.256777
0.137622
0.086014
1.0
12.8
Polished Copper
0.2295
0.08825
0.0275
1.0
0.5508
0.2118
0.066
1.0
0.580594
0.223257
0.0695701
1.0
51.2
Gold
0.24725
0.1995
0.0745
1.0
0.75164
0.60648
0.22648
1.0
0.628281
0.555802
0.366065
1.0
51.2
Polished Gold
0.24725
0.2245
0.0645
1.0
0.34615
0.3143
0.0903
1.0
0.797357
0.723991
0.208006
1.0
83.2
Pewter
0.105882
0.058824
0.113725
1.0
0.427451
0.470588
0.541176
1.0
0.333333
0.333333
0.521569
1.0
9.84615
Silver
0.19225
0.19225
0.19225
1.0
0.50754
0.50754
0.50754
1.0
0.508273
0.508273
0.508273
1.0
51.2
Polished Silver
0.23125
0.23125
0.23125
1.0
0.2775
0.2775
0.2775
1.0
0.773911
0.773911
0.773911
1.0
89.6
Emerald
0.0215
0.1745
0.0215
0.55
0.07568
0.61424
0.07568
0.55
0.633
0.727811
0.633
0.55
76.8
Jade
0.135
0.2225
0.1575
0.95
0.54
0.89
0.63
0.95
0.316228
0.316228
0.316228
0.95
12.8
Obsidian
0.05375
0.05
0.06625
0.82
0.18275
0.17
0.22525
0.82
0.332741
0.328634
0.346435
0.82
38.4
Pearl
0.25
0.20725
0.20725
0.922
1.0
0.829
0.829
0.922
0.296648
0.296648
0.296648
0.922
11.264
Ruby
0.1745
0.01175
0.01175
0.55
0.61424
0.04136
0.04136
0.55
0.727811
0.626959
0.626959
0.55
76.8
Turquoise
0.1
0.18725
0.1745
0.8
0.396
0.74151
0.69102
0.8
0.297254
0.30829
0.306678
0.8
12.8
Black Plastic
0.0
0.0
0.0
1.0
0.01
0.01
0.01
1.0
0.50
0.50
0.50
1.0
32
Black Rubber
0.02
0.02
0.02
1.0
0.01
0.01
0.01
1.0
0.4
0.4
0.4
1.0
10

Conclusion

More realistic light reflection calculations can be made if you know the specific color values for each type of reflected light. However, there are drawbacks to this idea:

  • This only applies to objects with uniform, “solid” color surfaces. Notice that most of the above examples are gems or precious metals, which have a uniform color over their entire surface. Most real-world objects do not have uniform surfaces.
  • You must have special equipment to measure the precise colors values for a particular type of object and most people do not have access to such special equipment.
  • It requires significant memory to store three separate colors for each vertex of a model. Separate color values for each type of reflected light is typically implemented as uniform variables for an entire model.

Glossary

ambient color
The amount of color reflected off of a surface from indirect light.
diffuse color
The amount of color reflected in all directions off of a surface from direct light.
specular color
The amount of color reflected directly into the camera off of a surface from direct light.
[1]The original source of this information was “http://www.sgi.com/software/opengl/advanced98/notes/node119.html” but the hyperlink is no longer valid.
Next Section - 10.3 - Smooth “Phong” Shading