Package com.luciad.view.lightspeed.style
Class TLspParameterizedFillStyle
java.lang.Object
com.luciad.view.lightspeed.style.ALspStyle
com.luciad.view.lightspeed.style.TLspParameterizedFillStyle
- All Implemented Interfaces:
ILspWorldElevationStyle
,ILspStyler
Style used to style
ILcdPolygon
. Most properties of this style
can be controlled through expressions
.
Construction of this style is done through its TLspParameterizedFillStyle.Builder
.
The following properties of this style are calculated by an expression:
- Color: the color of the fill of the polygon
For defaults, see TLspParameterizedFillStyle.Builder
.
TLcdColorMap colorMap = ...; TLcdDataProperty populationProperty = ...; ILcdExpressionIn this example, the fill color is based on the value of the populationProperty. The mapping between the population and the actual fill color is based on acolor = mixmap(toFloat(attribute(Integer.class,populationProperty)), colorMap); TLspParameterizedFillStyle style = TLspParameterizedFillStyle.newBuilder() .color(color) .build();
TLcdColorMap
.
Submitting a TLspParameterizedFillStyle
and TLspFillStyle
for the same domain object is not supported.
Only one of them will be used to visualize the domain object.
Note: TLcdExpressionFactory.viewPositionAttribute()
must not be used when the elevation mode is set to
ILspWorldElevationStyle.ElevationMode.ON_TERRAIN
or when the elevation mode is ILspWorldElevationStyle.ElevationMode.OBJECT_DEPENDENT
and
all z-values of the geometry are 0.- Since:
- 2018.0
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
Builder for parameterized fill styles.Nested classes/interfaces inherited from interface com.luciad.view.lightspeed.style.ILspWorldElevationStyle
ILspWorldElevationStyle.ElevationMode
-
Method Summary
Modifier and TypeMethodDescriptionCreates a new builder initialized with all the properties of this style.boolean
getColor()
Gets the color expression.Returns the elevation mode of this style.Returns the expression that determines transparency of the fill.Returns the expression that determines whether the object should be displayed or not.int
hashCode()
boolean
isCompatible
(TLspPaintPass aPaintPass) Utility method to determine whether the style is compatible with the given paint pass.boolean
Determines whether this style is transparent.static TLspParameterizedFillStyle.Builder
<?> Creates a new builder with the default values.Methods inherited from class com.luciad.view.lightspeed.style.ALspStyle
addStyleChangeListener, getZOrder, removeStyleChangeListener, style
-
Method Details
-
newBuilder
Creates a new builder with the default values.- Returns:
- the new builder.
-
asBuilder
Creates a new builder initialized with all the properties of this style. -
getColor
Gets the color expression.- Returns:
- the color
-
getOpacity
Returns the expression that determines transparency of the fill.- Returns:
- The expression
-
getVisibility
Returns the expression that determines whether the object should be displayed or not.- Returns:
- The expression
-
isTransparent
public boolean isTransparent()Description copied from class:ALspStyle
Determines whether this style is transparent. Shapes that are transparent can be painted in a different paint phase than shapes that are not transparent.- Specified by:
isTransparent
in classALspStyle
- Returns:
- whether or not this style is transparent
-
getElevationMode
Description copied from interface:ILspWorldElevationStyle
Returns the elevation mode of this style.- Specified by:
getElevationMode
in interfaceILspWorldElevationStyle
- Returns:
- The elevation mode.
-
isCompatible
Description copied from class:ALspStyle
Utility method to determine whether the style is compatible with the given paint pass. A style and paint pass are compatible if they use or request the same terrain and transparency properties.- Overrides:
isCompatible
in classALspStyle
- Parameters:
aPaintPass
- the paint pass- Returns:
true
if the style can be used in the given paint pass,false otherwise
.
-
equals
-
hashCode
public int hashCode()
-