PaletteSystemDefault8BppPalette(Color32, Byte) Method

Gets a Palette instance that uses the system default 8-bit palette. This palette contains the 16 standard basic sRGB colors, the "web-safe" palette of 216 colors as well as 24 transparent entries.
See the Remarks section of the PredefinedColorsQuantizer.SystemDefault8BppPalette method for details and some examples.

Definition

Namespace: KGySoft.Drawing.Imaging
Assembly: KGySoft.Drawing.Core (in KGySoft.Drawing.Core.dll) Version: 7.1.0
C#
public static Palette SystemDefault8BppPalette(
	Color32 backColor = default,
	byte alphaThreshold = 128
)

Parameters

backColor  Color32  (Optional)
Specifies the background color for lookup operations (GetNearestColor, GetNearestColorIndex). When a lookup is performed with a color, whose Color32.A field is equal to or greater than alphaThreshold, and there is no exact match among the palette entries, then the color to be found will be blended with this color before performing the lookup. The Color32.A field of the background color is ignored. This parameter is optional.
Default value: The default value of the Color32 type, which has the same RGB values as Black.
alphaThreshold  Byte  (Optional)
Specifies a threshold value for the Color32.A field, under which lookup operations will return the first transparent color (GetNearestColor) or the index of the first transparent color (GetNearestColorIndex). This parameter is optional.
Default value: 128.

Return Value

Palette
A Palette instance that uses the system default 8-bit palette.

See Also