Table of Contents

Method BlendColorsWAIP

Namespace
PaintDotNet
Assembly
PaintDotNet.Core.dll

BlendColorsWAIP(ColorBgra[], uint[])

Blends the colors based on the given weight values.

public static ColorBgra BlendColorsWAIP(ColorBgra[] c, uint[] w)

Parameters

c ColorBgra[]

The array of color values.

w uint[]

The array of weight values.

Returns

ColorBgra

The weights should be fixed point numbers. The total summation of the weight values will be treated as "1.0". Each color will be blended in proportionally to its weight value respective to the total summation of the weight values.

Remarks

"WAIP" stands for "weights, arbitrary integer precision"