Function
Creates a distant light Object of specified color and direction.
Syntax
#include <dx/dx.h>
Light DXNewDistantLight(Vector direction, RGBColor color)
Functional Details
The light source is located at an infinite distance from the scene in the specified direction. Shading from distant lights differs with orientation in relation to the light and not with the distance from the light.
The Light created can be deleted with DXDelete. See 4.2 , "Memory Management".
A
Vector
is defined as follows:
typedef struct point {
float x, y, z;
} Point, Vector;
An
RGBColor
is defined as follows:
typedef struct rgbcolor {
float r, g, b;
} RGBColor;
Return Value
Returns the Light or returns NULL and sets an error code.
See Also