CustomEffectBase.FromColor Method

Encodes the specified Color into an unsigned integer.

Namespace: Lumia.Imaging.Custom
Assembly: Lumia.Imaging.Managed (in Lumia.Imaging.Managed.dll) Version:

Lumia.Imaging.Custom.CustomEffectBase.FromColor = function(color);


Type: Windows.UI.Color
The Color to encode.

Return Value

Type: UInt32
The color represented as a UInt32 value.

If this method is called for every pixel in a buffer, the overhead of the function call becomes quite large. Then it is better to combine the color channel values inline, as in the following sample.
var color = (uint)(b | (g << 8) | (r << 16) | (a << 24));

Lumia Imaging SDK

Supported in: 2.0