RSL
|
Surface Shader AlgorithmWriting a shader is like preparing a meal. While different recipes use different ingredients, all recipes use a general set of rules as well as applying specific rules that make a particular dish unique. An algorithm is a list of rules that must be followed to achieve a certain result. The purpose of a surface shader is to
The renderer uses the opacity information to 'mix' background and foreground surface colors so that background objects in a 3D scene will "show through" any semi-transparent foreground objects. The following algorithm (recipe) lists the four steps that the standard shader, plastic, follows in order to set the appropriate opacity and color of the point on the surface of an object that is being shaded,
|
|||||||||||||||||||||||||
The Geometry of Shading
The Components of Lighting
|
Surface Shading & Global VariablesThe following table lists the global variables accessible to a surface shader. Those shown in red are "read-only", those in green are the variables to which a surface shader must assign values.
|
© 2002- Malcolm Kesson. All rights reserved.