Vertex color

From polycount
Revision as of 11:14, 15 January 2011 by EricChadwick (Talk)

Jump to: navigation, search

Vertex Color

Each vertex in a mesh can optionally store a RGB color value, called vertex color. These can be used for a variety of interesting effects and shader inputs.

Vertices can also store vertex alpha, which can be used for multitexturing,, or ambient occlusion.


Usage

Vertex color is typically multiplied against the Diffuse Color, colorizing/darkening the color map.

Vertex color can also be used for controlling blends between different texture sets, providing per-vertex sound effects in response to collisions, controlling which foliage vertices are affected by a "wind" vertex shader, etc.

When used for non-color effects, typically each color channel is treated as a separate monochrome set of values, so for example RGB vertex color can control three different per-vertex effects.

Multiple Colors per Vertex

A single vertex can be assigned multiple vertex colors, depending on the game engine and mesh format. This duplicates the vertex when it is loaded into the game, once for each color, slightly increasing the memory cost.

When vertices along an edge contain two different vertex colors, the color may change suddenly from one triangle to the next, creating a hard color edge. Some authoring tools let you create this kind of effect by letting you assign vertex colors to a selection of polygons instead of just vertex by vertex.

Tutorials

Foliage Vertex Color
Ambient-Occlusion Vertex Color
Removing Vertex Colors
Vertex Color Tutorial for 3ds Max
Vertex Color Use in Maya Questions

Personal tools
Namespaces

Variants
Actions
Navigation
Tools