public class TLcdKML22Lod extends TLcdKML22AbstractObject
OGC KML Specification description:
This element can be used wherever the following element is referenced: -kml:AbstractObjectGroup Specifies the level of detail to use when displaying a kml:Region. An earth browser should calculate the size of the kml:Region when projected onto screen space then compute the square root of the kml:Region's area. For example, if an untiled kml:Region is square and the viewpoint is directly above the kml:Region, this measurement is equal to the width of the projected kml:Region. If this measurement falls within the limits defined by kml:minLodPixels and kml:maxLodPixels, and if the kml:LatLonAltBox is in view, then the kml:Region should be activated. If this limit is not reached, the associated geometry should not be drawn since it would be too far from the user's viewpoint to be visible. kml:minLodPixels shall be less than kml:maxLodPixels (where a value of -1 = infinite). It is also advised that kml:minFadeExtent + kml:maxFadeExtent is less than or equal to kml:maxLodPixels - kml:minLodPixels. The following diagram demonstrates how kml:Lod is used in the determination of the visibility of a region: In the following diagram, if P=the calculated projected pixel size, the circled numbers indicate the following: if (P < minLodPixels) opacity=0 //#1 in diagram else if(P < minLodPixels + minFadeExtent) opacity=(P - minLodPixels)/minFadeExtent //#2 in diagram else if (P < maxLodPixels - maxFadeExtent) opacity=1 //#3 in diagram else if (P < maxLodPixels) opacity=(maxLodPixels-P)/maxFadeExtent //#4 in diagram else opacity=0 //#5 in diagram kml:Lod shall contain the kml:minLodPixels outside of an update context, that is when not a descendant of kml:Update. See also 9.13 kml:Region.
Modifier and Type | Field and Description |
---|---|
static TLcdDataProperty |
LOD_OBJECT_EXTENSION_GROUP_PROPERTY
Data property that maps to the
LodObjectExtensionGroup element. |
static TLcdDataProperty |
LOD_SIMPLE_EXTENSION_GROUP_PROPERTY
Data property that maps to the
LodSimpleExtensionGroup element. |
static TLcdDataProperty |
MAX_FADE_EXTENT_PROPERTY
Data property that maps to the
maxFadeExtent element. |
static TLcdDataProperty |
MAX_LOD_PIXELS_PROPERTY
Data property that maps to the
maxLodPixels element. |
static TLcdDataProperty |
MIN_FADE_EXTENT_PROPERTY
Data property that maps to the
minFadeExtent element. |
static TLcdDataProperty |
MIN_LOD_PIXELS_PROPERTY
Data property that maps to the
minLodPixels element. |
ID_PROPERTY, OBJECT_SIMPLE_EXTENSION_GROUP_PROPERTY, TARGET_ID_PROPERTY
Constructor and Description |
---|
TLcdKML22Lod(TLcdDataType aType)
Creates a new
TLcdKML22Lod with a custom TLcdDataType . |
Modifier and Type | Method and Description |
---|---|
Double |
getMaxFadeExtent()
Returns the value of the property that maps to the
maxFadeExtent element. |
Double |
getMaxLodPixels()
Returns the value of the property that maps to the
maxLodPixels element. |
Double |
getMinFadeExtent()
Returns the value of the property that maps to the
minFadeExtent element. |
Double |
getMinLodPixels()
Returns the value of the property that maps to the
minLodPixels element. |
void |
setMaxFadeExtent(Double aValue)
Sets the value of the property that maps to the
maxFadeExtent element. |
void |
setMaxLodPixels(Double aValue)
Sets the value of the property that maps to the
maxLodPixels element. |
void |
setMinFadeExtent(Double aValue)
Sets the value of the property that maps to the
minFadeExtent element. |
void |
setMinLodPixels(Double aValue)
Sets the value of the property that maps to the
minLodPixels element. |
getId, getTargetId, setId, setTargetId
public static final TLcdDataProperty MIN_LOD_PIXELS_PROPERTY
minLodPixels
element.
The possible values for this property are instances of Double
.public static final TLcdDataProperty MAX_LOD_PIXELS_PROPERTY
maxLodPixels
element.
The possible values for this property are instances of Double
.public static final TLcdDataProperty MIN_FADE_EXTENT_PROPERTY
minFadeExtent
element.
The possible values for this property are instances of Double
.public static final TLcdDataProperty MAX_FADE_EXTENT_PROPERTY
maxFadeExtent
element.
The possible values for this property are instances of Double
.public static final TLcdDataProperty LOD_SIMPLE_EXTENSION_GROUP_PROPERTY
LodSimpleExtensionGroup
element.
The possible values for this property are instances of List<String>
.public static final TLcdDataProperty LOD_OBJECT_EXTENSION_GROUP_PROPERTY
LodObjectExtensionGroup
element.
The possible values for this property are instances of List<TLcdKML22AbstractObject>
.public TLcdKML22Lod(TLcdDataType aType)
TLcdKML22Lod
with a custom TLcdDataType
.aType
- a TLcdDataType
.public Double getMinLodPixels()
minLodPixels
element.MIN_LOD_PIXELS_PROPERTY
property.public void setMinLodPixels(Double aValue)
minLodPixels
element.aValue
- the value to set for the MIN_LOD_PIXELS_PROPERTY
property.public Double getMaxLodPixels()
maxLodPixels
element.MAX_LOD_PIXELS_PROPERTY
property.public void setMaxLodPixels(Double aValue)
maxLodPixels
element.aValue
- the value to set for the MAX_LOD_PIXELS_PROPERTY
property.public Double getMinFadeExtent()
minFadeExtent
element.MIN_FADE_EXTENT_PROPERTY
property.public void setMinFadeExtent(Double aValue)
minFadeExtent
element.aValue
- the value to set for the MIN_FADE_EXTENT_PROPERTY
property.public Double getMaxFadeExtent()
maxFadeExtent
element.MAX_FADE_EXTENT_PROPERTY
property.public void setMaxFadeExtent(Double aValue)
maxFadeExtent
element.aValue
- the value to set for the MAX_FADE_EXTENT_PROPERTY
property.