Defining Lights

Overview

Light data are defined in <FragmentLightCtr> below <Lights>. Where there are multiple sets of light data, there are multiple <FragmentLightCtr> tags below the <Lights> tag. <FragmentLightCtr> contains the following light-related information:

Light Type

There are three light types, as listed below. The light type is specified by the LightKind attribute of the <FragmentLightCtr> tag.

Light SRT Information

This stores information about the light's position, rotation and scaling.

<NintendoWareIntermediateFile>
<GraphicsContentCtr>
<Lights>
<FragmentLightCtr>
<Transform>

Light Color Information

The four following parameters are stored as the light color information. These color parameters are used for all the types of lights.

Light direction

The direction that the light is pointing is specified by a vector. This parameter is configured when specifying the direction of a directional light or a spot light.

<NintendoWareIntermediateFile>
<GraphicsContentCtr>
<Lights>
<FragmentLightCtr>
<Direction>

Attenuation Inside Spotlight Cone

This is the setting for the attenuation inside the spotlight cone. This specifies a table used with the <ReferenceLookupTableCtr> tag. This table is defined as a lookup table of cosine values of the angle formed from the light vector and the spot-direction vector.

<NintendoWareIntermediateFile>
<GraphicsContentCtr>
<Lights>
<FragmentLightCtr>
<AngleSampler>
<ReferenceLookupTableCtr>
<LookupTableSetContentReferenceCtr>

CONFIDENTIAL