public class ElevationBandGenerator extends SimpleColorGenerator
SimpleColorGenerator.ByteRasterHelper, SimpleColorGenerator.CharRasterHelper, SimpleColorGenerator.DoubleRasterHelper, SimpleColorGenerator.FloatRasterHelper, SimpleColorGenerator.IntRasterHelper, SimpleColorGenerator.RasterHelper, SimpleColorGenerator.ShortRasterHelper
Modifier and Type | Field and Description |
---|---|
protected int |
adjust
A number between 1-5 to adjust the contrast a little between the colors.
|
protected int |
bandHeight
The elevation difference between the edges of a color - or how much the
elevation must change before a pixel gets the next color.
|
protected int[] |
colors
The colors to use.
|
protected Length |
dataUnits |
static int |
DEFAULT_ADJUST |
static int |
DEFAULT_BANDHEIGHT |
protected Length |
displayUnits |
Constructor and Description |
---|
ElevationBandGenerator() |
Modifier and Type | Method and Description |
---|---|
int |
calibratePointValue(int source)
Takes the value assigned to a pixel, as determined by it's location in
the grid, and gives it a color to be painted by.
|
int |
getAdjust() |
int |
getBandHeight() |
int[] |
getColortable() |
Length |
getDataUnits() |
Length |
getDisplayUnits() |
void |
setAdjust(int value) |
void |
setBandHeight(int height) |
void |
setColors(ElevationColors ec) |
void |
setColortable(int[] colors) |
void |
setDataUnits(Length units) |
void |
setDisplayUnits(Length displayUnits) |
createGreyscaleColors, generate, getRasterHelper, needGenerateToRender
public static final int DEFAULT_BANDHEIGHT
public static final int DEFAULT_ADJUST
protected int[] colors
protected int adjust
protected int bandHeight
protected Length dataUnits
protected Length displayUnits
public int calibratePointValue(int source)
calibratePointValue
in class SimpleColorGenerator
source
- a grid point value assigned to the raster pixel.public void setColortable(int[] colors)
public int[] getColortable()
public void setColors(ElevationColors ec)
public void setBandHeight(int height)
public int getBandHeight()
public void setAdjust(int value)
public int getAdjust()
public Length getDataUnits()
public void setDataUnits(Length units)
public Length getDisplayUnits()
public void setDisplayUnits(Length displayUnits)
Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details