Color Blend Modes

From IncendiaWiki
Jump to: navigation, search

Color Blend Modes.jpg

Introduction

Color Blending modes are now supported on Incendia Expanded in two different sections, one in the Baseshape Editor and the other in the Render Panel. Eight modes are now defined and in the future more will be added.

Color Blending Modes

The following Eight Color combination Modes are supported:

Addition

The color components (RGB) are added and if the resulting values are greater than 255, the value is clamped to 255.

Multiply

The color components (RGB) are multiplied and the result is divided by 255.

Average

The color components (RGB) are averaged (added then divided by 2).

Difference

The final color is the absolute value of the subtraction of the color components (RGB).

Darken

The color is calculated as the minimum value of the color components (RGB).

Lighten

The color is calculated as the maximum value of the color components (RGB).

Screen

The color is calculated as the inverted, multiplied, and inverted color components (RGB).

Negation

The color is calculated according the following formula:
result=1 - |1 - a - b|
on where:
a=First color component (RGB)
b=Second color component (RGB)

Color Blending in the Baseshape Editor

The Color Blending option in the baseshape editor is enabled when both Surface Texture and Gradient Iteration options are selected:
Baseshape Color Options.jpg

The color blend is calculated between the surface texture and the gradient.
The following table shows the result of the different modes:


Is important to note: When the Surface Texture is enabled, the default image is a black texture, so when the multiply mode is selected, the result is black, thats due to the mutiplication by zero.

Color Blending in the Render Panel

The Color Blending control in the Render panel is located under the Advanced Tab:
Render Panel Color Blend Control.jpg

The Color Blending in the Render panel is the result of the combination of the baseshape colors and the light texture colors (ambient and diffuse components).
Since not all baseshapes has colors, in those cases, Incendia assign them a black color.
The following table shows the result of the different modes: