Method Create
Create(IEnumerable<Color>)
Creates a colormap from a set of colors. Raster value of 0 maps to the first color, with each consecutive value mapping to the next color.
Declaration
public static Colormap Create(IEnumerable<Color> colors)
Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<Color> | colors | An collection of colors. |
Returns
| Type | Description |
|---|---|
| Colormap | Colormap |
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET Standard 2.0 | 100.3 - 200.8 |
| .NET | 100.13 - 300.0 |
| .NET Windows | 100.13 - 300.0 |
| .NET Android | 200.2 - 300.0 |
| .NET iOS | 200.0 - 300.0 |
| .NET Framework | 100.3 - 200.8 |
| Xamarin.Android | 100.0 - 100.14 |
| Xamarin.iOS | 100.0 - 100.15 |
| UWP | 100.3 - 200.8 |
Create(IEnumerable<KeyValuePair<int, Color>>)
Creates a colormap with the specified mapping of raster values to colors.
Declaration
public static Colormap Create(IEnumerable<KeyValuePair<int, Color>> colorMappings)
Parameters
| Type | Name | Description |
|---|---|---|
| IEnumerable<KeyValuePair<int, Color>> | colorMappings | A dictionary of values with corresponding colors. |
Returns
| Type | Description |
|---|---|
| Colormap | A new colormap object. |
Applies to
Platforms and versions
| Target | Versions |
|---|---|
| .NET | 300 |
| .NET Windows | 300 |
| .NET Android | 300 |
| .NET iOS | 300 |