Share via


ShadeMode Enumeration (Microsoft.DirectX.Direct3D)

Defines constants that describe the supported shading modes.

Definition

Visual Basic Public Enum ShadeMode
C# public enum ShadeMode
C++ public enum class ShadeMode
JScript public enum ShadeMode

Members

Member Value Description
Phong 3 Not supported.
Gouraud 2 Gouraud shading mode. The color and specular components of the face are determined by a linear interpolation between all three of the triangle's vertices.
Flat 1 Flat shading mode. The color and specular component of the first vertex in the triangle are used to determine the color and specular component of the face. These colors remain constant across the triangle; that is, they are not interpolated. The specular alpha is interpolated.

Remarks

The first vertex of a triangle for flat shading mode is defined in the following manner.

  • For a Triangle Lists, the first vertex of the triangle i is i * 3.
  • For a Triangle Strips, the first vertex of the triangle i is vertex i.
  • For a Triangle Fans, the first vertex of the triangle i is vertex i + 1.

Enumeration Information

Namespace Microsoft.DirectX.Direct3D
Assembly Microsoft.DirectX.Direct3D (microsoft.directx.direct3d.dll)
Strong Name Microsoft.DirectX.Direct3D,  Version=1.0.900.0,  Culture=neutral,  PublicKeyToken=d3231b57b74a1492