VRML_LIGHT Procedure

Sets up the light source for a VRML world.

Usage

VRML_LIGHT, position

Input Parameters

position—A 3-element array specifying the positioning of the light source.

Keywords

Color—A 3-element array of RGB values, in the range of 0 to 255. (Default: [255, 255, 255], the color white)

Intensity—A number normalized from 0 to 1, where 1 is full intensity. (Default:1)

Discussion

VRML supports three node types to control lighting. The VRML_LIGHT procedure implements one of the types, the PointLight, which emanates light radially in all directions.

Note:

See the VRML_SPOTLIGHT procedure for another implementation of the VRML node types to control lighting.

Example

VRML_OPEN, 'vrml_light.wrl'
...
VRML_LIGHT, [-1, -1, 0], Color = [255, 0, 0], Intensity = 1.0
VRML_CLOSE

See Also

VRML_CAMERAVRML_SPOTLIGHT

For a discussion of VRML lighting, see The VRML Sourcebook, by Andrea L. Ames, et al., John Wiley & Sons, Inc., 1996, Chapter 19.