Package com.luciad.view.lightspeed.style
Class TLspIndexColorModelStyle.Builder<B extends TLspIndexColorModelStyle.Builder<B>>
java.lang.Object
com.luciad.view.lightspeed.style.ALspStyle.Builder<B>
com.luciad.view.lightspeed.style.TLspIndexColorModelStyle.Builder<B>
- Enclosing class:
TLspIndexColorModelStyle
public static class TLspIndexColorModelStyle.Builder<B extends TLspIndexColorModelStyle.Builder<B>>
extends ALspStyle.Builder<B>
Builder for index color model styles.
The default index color style has a 8-bit color model
of size 256 that interpolates between blue, cyan, yellow,
orange, and red colors. It is not draped, nor transparent.
- Since:
- 2012.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionSets this builder's properties to the given style's properties.build()
Constructs an index color model style with the set properties.defaultColorModel
(float aAlpha) Convenience method to set the color model to the default color model with colors having the given alpha value.indexColorModel
(IndexColorModel aIndexColorModel) Sets the index color model.layer
(int aLayer) Sets the layer this style belongs to.scaleFactor
(float aScaleFactor) Sets a scale factor with which values are multiplied prior to looking them up in the color model.transparent
(boolean aTransparent) Sets whether the color model used by this style uses transparent colors.Methods inherited from class com.luciad.view.lightspeed.style.ALspStyle.Builder
equals, hashCode
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
layer
Sets the layer this style belongs to. Layers should be painted from lowest to highest layer number. Increasing the number of layers can negatively impact painting performance. Therefore the number of separate layers should be kept to a minimum.- Parameters:
aLayer
- the layer- Returns:
this
-
transparent
Sets whether the color model used by this style uses transparent colors.- Parameters:
aTransparent
- true if the color model is transparent, false otherwise- Returns:
this
-
indexColorModel
Sets the index color model. This indexed color model should never be modified. To change the indexed color model you should create a new style with a different indexed color model instance.- Parameters:
aIndexColorModel
- the index color model- Returns:
- @code this}
-
defaultColorModel
Convenience method to set the color model to the default color model with colors having the given alpha value.- Parameters:
aAlpha
- the alpha value for the colors in the index color model- Returns:
this
-
scaleFactor
Sets a scale factor with which values are multiplied prior to looking them up in the color model.- Parameters:
aScaleFactor
- the scale factor- Since:
- 2017.1
-
all
Sets this builder's properties to the given style's properties.- Specified by:
all
in classALspStyle.Builder<B extends TLspIndexColorModelStyle.Builder<B>>
- Parameters:
aIndexColorModelStyle
- the style to copy- Returns:
this
-
build
Constructs an index color model style with the set properties.- Specified by:
build
in classALspStyle.Builder<B extends TLspIndexColorModelStyle.Builder<B>>
- Returns:
- the resulting style
-