BitmapPalettes Class
Defines several color palettes that are commonly used by bitmap images.
Assembly: PresentationCore (in PresentationCore.dll)
| Name | Description | |
|---|---|---|
![]() ![]() | BlackAndWhite | Gets a value that represents a black-and-white color palette. This palette consists of 2 colors total. |
![]() ![]() | BlackAndWhiteTransparent | Gets a value that represents a black, white, and transparent color palette. This palette consists of 3 colors total. |
![]() ![]() | Gray16 | Gets a value that represents a color palette that contains 16 shades of gray. The palette ranges from black to gray to white. This palette contains 16 total colors. |
![]() ![]() | Gray16Transparent | Gets a value that represents a color palette that contains 16 shades of gray. The palette ranges from black to gray to white with an additional transparent color. This palette contains 17 total colors. |
![]() ![]() | Gray256 | Gets a value that represents a color palette that contains 256 shades of gray, ranging from black to gray to white. This palette contains 256 total colors. |
![]() ![]() | Gray256Transparent | Gets a value that represents a color palette that contains 256 shades of gray, ranging from black to gray to white with an additional transparent color. This palette contains 257 total colors. |
![]() ![]() | Gray4 | Gets a value that represents a color palette that contains 4 shades of gray, ranging from black to gray to white. This palette contains 4 total colors. |
![]() ![]() | Gray4Transparent | Gets a value that represents a color palette that contains 4 shades of gray, ranging from black to gray to white with an additional transparent color. This palette contains 5 total colors. |
![]() ![]() | Halftone125 | Gets a value that represents a color palette that contains 125 primary colors and 16 system colors, with duplicate colors removed. There are a total of 133 colors in this palette. |
![]() ![]() | Halftone125Transparent | Gets a value that represents a color palette that contains 125 primary colors, 16 system colors, and 1 additional transparent color. Duplicate colors in the palette are removed. There are a total of 134 colors in this palette. |
![]() ![]() | Halftone216 | Gets a value that represents a color palette that contains 216 primary colors and 16 system colors, with duplicate colors removed. There are a total of 224 colors in this palette. |
![]() ![]() | Halftone216Transparent | Gets a value that represents a color palette that contains 216 primary colors, 16 system colors, and 1 additional transparent color. Duplicate colors in the palette are removed. There are a total of 225 colors in this palette. |
![]() ![]() | Halftone252 | Gets a value that represents a color palette that contains 252 primary colors and 16 system colors, with duplicate colors removed. There are a total of 256 colors in this palette. |
![]() ![]() | Halftone252Transparent | Gets a value that represents a color palette that contains 252 primary colors, 16 system colors, and 1 additional transparent color. Duplicate colors in the palette are removed. There are a total of 256 colors in this palette. |
![]() ![]() | Halftone256 | Gets a value that represents a color palette that contains 256 primary colors and 16 system colors, with duplicate colors removed. There are a total of 256 colors in this palette. |
![]() ![]() | Halftone256Transparent | Gets a value that represents a color palette that contains 256 primary colors, 16 system colors, and 1 additional transparent color that replaces the final color in the sequence. Duplicate colors in the palette are removed. There are a total of 256 colors in this palette. |
![]() ![]() | Halftone27 | Gets a value that represents a color palette that contains 27 primary colors and 16 system colors, with duplicate colors removed. There are a total of 35 colors in this palette. |
![]() ![]() | Halftone27Transparent | Gets a value that represents a color palette that contains 27 primary colors and 16 system colors, with duplicate colors removed and 1 additional transparent color. There are a total of 36 colors in this palette. |
![]() ![]() | Halftone64 | Gets a value that represents a color palette that contains 64 primary colors and 16 system colors, with duplicate colors removed. There are a total of 72 colors in this palette. |
![]() ![]() | Halftone64Transparent | Gets a value that represents a color palette that contains 64 primary colors and 16 system colors, with duplicate colors removed and 1 additional transparent color. There are a total of 73 colors in this palette. |
![]() ![]() | Halftone8 | Gets a value that represents a color palette that contains 8 primary colors and 16 system colors, with duplicate colors removed. There are a total of 16 colors in this palette, which are the same as the system palette. |
![]() ![]() | Halftone8Transparent | Gets a value that represents a color palette that contains 8 primary colors and 16 system colors, with duplicate colors removed and 1 additional transparent color. There are a total of 17 colors in this palette. |
![]() ![]() | WebPalette | Gets a value that represents a color palette that contains 216 primary colors and 16 system colors, with duplicate colors removed. There are a total of 224 colors in this palette. |
![]() ![]() | WebPaletteTransparent | Gets a value that represents a color palette that contains 216 primary colors and 16 system colors, with duplicate colors removed and 1 additional transparent color. There are a total of 225 colors in this palette. |
BitmapPalettes properties whose names end with "Transparent" have an additional "color" that is fully transparent. In the case of palettes that already have 256 colors, the last color is replaced by the transparent color.
Only Tagged Image File Format (TIFF) and Graphics Interchange Format (GIF) image formats support palettes.
The following code example demonstrates how to construct a new BitmapSource by using a member of the BitmapPalettes class in a similar way.
Available since 3.0
Any public static ( Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

