Skip to main content

Order & Blending

The shader is a combination of various modules that are evaluated in a particular order and are then blended together.

You can think of these modules as layers in a painting program. Each layer has csome kind of color content and then each layer has an opacity and a blend mode. Same thing here. Each module has color content, a blend mode and an opacity.

Blending

Blending is done by combining the "source" (the module we just calculated) with the "destination" (the colors we've blended up to this point so far, and we're blending into)

The following blend modes are available:

Standard

This is the typical alpha blend. This will use the alpha of the source to blend with the destination.

Additive

This will add the source color and alpha to the destination color and alpha.

Multiply

This will multiply the source and the destination color and alphas together. Great for masking alpha or adding color to a white surface.

Opacity

The opacity slider controls how much of the blended result will actually be used. So an opacity of 0 means that no blending will occur. An opacity of 0.5 means that the source and destination will be blended but only half of that result will continue forward. Etc.

Order

The shader features are evaluated in the following order (the top ones being the first ones to be calculated, bottom ones being the last):