org.opensourcephysics.display2d
Class VectorColorMapper
java.lang.Object
org.opensourcephysics.display2d.VectorColorMapper
- public class VectorColorMapper
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SPECTRUM
public static final int SPECTRUM
- See Also:
- Constant Field Values
RED
public static final int RED
- See Also:
- Constant Field Values
BLUE
public static final int BLUE
- See Also:
- Constant Field Values
GREEN
public static final int GREEN
- See Also:
- Constant Field Values
BLACK
public static final int BLACK
- See Also:
- Constant Field Values
VectorColorMapper
public VectorColorMapper(int _numColors,
double _ceil)
getFloor
public double getFloor()
getCeiling
public double getCeiling()
setPaletteType
protected void setPaletteType(int _paletteType)
- Sets the color palette.
- Parameters:
_paletteType
-
checkPallet
protected void checkPallet(java.awt.Color backgroundColor)
setScale
public void setScale(double _ceil)
- Sets the scale.
- Parameters:
_ceil
-
doubleToColor
public java.awt.Color doubleToColor(double mag)
- Converts a double to a color.
- Parameters:
mag
-
- Returns:
- the color
showLegend
public javax.swing.JFrame showLegend()