Package org.ka2ddo.yaac.gui
Class TopoLayer.ElevationColor
java.lang.Object
org.ka2ddo.yaac.gui.TopoLayer.ElevationColor
- All Implemented Interfaces:
Serializable
,Cloneable
- Enclosing class:
- TopoLayer
Object representing a rendering color and corresponding elevation level in meters.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionint
The alpha (transparency) of this object, from 0 to 255.int
The blue color strength of this object, from 0 to 255.int
The elevation value in the default shortDistanceUnit
.int
The green color strength of this object, from 0 to 255.int
The red color strength of this object, from 0 to 255.int
-
Method Summary
Modifier and TypeMethodDescriptionclone()
Creates and returns a copy of this object.boolean
Indicates whether some other object is "equal to" this one.long
Return encoding for storing an ElevationColor in the Preferences.int
hashCode()
Returns a hash code value for the object.void
setColor
(int argb) Set the ElevationColor's color to the specified ARGB value.void
Set the Color associated with this elevation.void
setEncoding
(long enc) Set the ElevationColor to the values associated with the internal encoding.
-
Field Details
-
elevation
public int elevationThe elevation value in the default shortDistanceUnit
. -
red
public int redThe red color strength of this object, from 0 to 255. -
green
public int greenThe green color strength of this object, from 0 to 255. -
blue
public int blueThe blue color strength of this object, from 0 to 255. -
alpha
public int alphaThe alpha (transparency) of this object, from 0 to 255. -
rgb
public int rgb
-
-
Method Details
-
setColor
Set the Color associated with this elevation.- Parameters:
color
- Color to use
-
clone
Creates and returns a copy of this object. -
equals
Indicates whether some other object is "equal to" this one. -
hashCode
public int hashCode()Returns a hash code value for the object. -
getEncoding
public long getEncoding()Return encoding for storing an ElevationColor in the Preferences.- Returns:
- long encoding of ElevationColor's internal value
-
setEncoding
public void setEncoding(long enc) Set the ElevationColor to the values associated with the internal encoding.- Parameters:
enc
- long encoding value
-
setColor
public void setColor(int argb) Set the ElevationColor's color to the specified ARGB value.- Parameters:
argb
- ARGB value of color to set
-