Bewerken

Delen via


Lighting

Lights are used to illuminate objects in a scene. The color of each object vertex is based on the current texture map, vertex colors, and light sources.

Note   This section is only for the fixed-function pipeline. Programmable shaders perform all lighting explicitly.

 

In this section

Topic Description

Lighting overview

When you use Direct3D lighting, you allow Direct3D to handle the details of illumination for you. Advanced users can perform lighting on their own, if desired.

Light types

The light type property defines which type of light source you're using. There are three types of lights in Direct3D - point lights, spotlights, and directional lights.

Light properties

Light properties describe a light source's type (point, directional, spotlight), attenuation, color, direction, position, and range.

Mathematics of lighting

The Direct3D Light Model covers ambient, diffuse, specular, and emissive lighting. This is enough flexibility to solve a wide range of lighting situations. The total amount of light in a scene is called the global illumination.

 

Direct3D Graphics Learning Guide