[]
        
(Showing Draft Content)

GrapeCity.Documents.Imaging.Windows.GcWicBitmap.CreatePredefinedPalette

CreatePredefinedPalette Method

CreatePredefinedPalette(WicPaletteType, bool)

Creates one of the pre-defined palettes specified by PaletteType and optionally adds a transparent color.

Declaration
public GcWicBitmap.Palette CreatePredefinedPalette(WicPaletteType paletteType, bool addTransparentColor)
Public Function CreatePredefinedPalette(paletteType As WicPaletteType, addTransparentColor As Boolean) As GcWicBitmap.Palette
Parameters
Type Name Description
WicPaletteType paletteType

The desired pre-defined palette type.

bool addTransparentColor

The optional transparent color to add to the palette. If no transparent color is needed, use false. When initializing to a grayscale or black and white palette, set this parameter to false.

Returns
Type Description
GcWicBitmap.Palette
Remarks

For palettes with less than 256 entries, the transparent entry is added to the end of the palette (that is, a 16-color palette becomes a 17-color palette). For palettes with 256 colors, the transparent palette entry will replace the last entry in the pre-defined palette.