This documentation is for the old version. Go to the latest Graphics Mill docs

ColorAdjustmentProvider.ChannelBalance Method

Adjusts balance between color channels (by adding a constant to each channel).

Namespace: Aurigma.GraphicsMill
Assembly: Aurigma.GraphicsMill (in Aurigma.GraphicsMill.dll)

Syntax

Visual Basic
Public Sub ChannelBalance ( _
	levels As Single() _
)
C#
public void ChannelBalance(
	float[] levels
)

Parameters

levels

Type: System.Single []

Each entry of array is a value varying in range [-1, 1].

Remarks

You can also use ChannelBalance class to apply this correction.

All values from levels parameter are normalized to 1. Depending on pixel format they are scaled to 255 or 65355 inside of the method.

Examples

Visual Basic
Dim channelBalance As New Aurigma.GraphicsMill.Transforms.ChannelBalance
'Picture has Format24bppRgb pixel format
'R: 0.2F  G: -0.1F  B: 0.05F
channelBalance.Levels = New Single(2) {0.2F, -0.1F, 0.05F}
channelBalance.ApplyTransform(bitmap)
C#
//Picture has Format24bppRgb pixel format
//R: 0.2F  G: -0.1F  B: 0.05F
bitmap.ColorAdjustment.ChannelBalance(new Single[3] {0.2F, -0.1F, 0.05F});

See Also

Reference