3D Parameter Window – OpenGL – Light
Fig.: 3D Parameters – Light Tab Here you can define upto 8 light sources which illuminate your fractal scene. You select a light by clicking onto the light bulb. You switch it on and off using the checkbox labeled “Enabled”. The light bulb icon will display the state (i.e. enabled/disabled). Each light source has its own set of parameters. First of all, the color of the light is specified by the following three components:
|
Each component of a light source has two properties: Its intensity (from 0 to 5, adjusted using the slider) and the color itself. You adjust the color by clicking onto the color selector field (the small colored circle). The Colorselection window will appear: This window lets you choose the color using either manual input into the entry fields using the RGB or HSL color model or by selecting the color from the colorwheel. |
The remaining parameters for each light are:
- Position: The position of a light source is specified using the standard positioning window in ChaosPro.
- Positional/Directional: Specifies whether the light should be treated as a positional or a directional light source:
Positional light sources have a “position”, directional light sources don’t have a position: A directional light source appears to illuminate all objects with equal intensity, as if it were at an infinite distance from the object. Directional light has orientation but no position. It is commonly used to simulate distant light sources, such as the sun. It is the best choice of light to use for maximum rendering speed.
Some global light parameters can be set, too: These are:
- Ambient: In addition to the ambient light of each light source a global ambient light can be specified. This ambient light is light that doesn’t come from any particular direction. All the objects in your scene will be lit up by this ambient light.
- Local Viewer: This parameter specifies how specular reflection angles are computed. If it is switched off, specular reflection angles take the view direction to be parallel to and in the direction of the -z axis, regardless of the location of the vertex in eye coordinates. Otherwise specular reflections are computed from the origin of the eye coordinate system. Got it? Well in other words: If switched off, reflection is calculated as if the observer was in front of the object regardless his actual position (which speeds up the calculation). If switched on, reflection is calculated correctly.
- Two Side: This parameter specifies whether one- or two-sided lighting calculations are done for polygons. If it is switched off, only the front material parameters are used in the lighting equation. Otherwise, two-sided lighting is specified. In this case, vertices of back-facing polygons are lighted using the back material parameters, and have their normals reversed before the lighting equation is evaluated. Vertices of front-facing polygons are always lighted using the front material parameters, with no change to their normals.