-
public class GradientA class to generate a color map from a given array of colors and the fractions that the colors represent by interpolating between their HSV values. This color map is to be used in the HeatmapTileProvider.
-
-
Field Summary
Fields Modifier and Type Field Description public final intmColorMapSizepublic Array<int>mColorspublic Array<float>mStartPoints
-
Constructor Summary
Constructors Constructor Description Gradient(Array<int> colors, Array<float> startPoints)Creates a Gradient with the given colors and starting points.These are given as parallel arrays. Gradient(Array<int> colors, Array<float> startPoints, int colorMapSize)Creates a Gradient with the given colors and starting points which creates a colorMap of given size.The colors and starting points are given as parallel arrays.
-
-
-
Constructor Detail
-
Gradient
Gradient(Array<int> colors, Array<float> startPoints)
Creates a Gradient with the given colors and starting points.These are given as parallel arrays.- Parameters:
colors- The colors to be used in the gradientstartPoints- The starting point for each color, given as a percentage of the maximum intensityThis is given as an array of floats with values in the interval [0,1]
-
Gradient
Gradient(Array<int> colors, Array<float> startPoints, int colorMapSize)
Creates a Gradient with the given colors and starting points which creates a colorMap of given size.The colors and starting points are given as parallel arrays.- Parameters:
colors- The colors to be used in the gradientstartPoints- The starting point for each color, given as a percentage of the maximum intensityThis is given as an array of floats with values in the interval [0,1]colorMapSize- The size of the colorMap to be generated by the Gradient
-
-