Child pages
  • PolygonFeature
Skip to end of metadata
Go to start of metadata

<PolygonFeature> is an XML way to define a list of points and have them visualized as a filled polygon region.  Polygon Features can be defined as flat regions, or extruded regions with "walls" on all sides.

Here are the following options for <PolygonFeature>:

<PolygonFeature> attribute(s):
boolean ShowAtStartup (Required) defines whether to show this feature on application startup (also depends on the parent <LayerSet>

<PolygonFeature> element(s):
string <Name> (Required) defines the name of the {{<PolygonFeature>
boolean <Extrude> (Optional - default=false) defines whether to have extrusion
number <ExtrudeHeight> (Optional - default=1000) in meters
boolean <ExtrudeUpwards> (Optional - default=true) defines whether to have the extrusion go up or down from the defined <LinearRing>
boolean <ExtrudeToGround> (Optional - default=false) defines whether to have the extrusion go from the defined <LinearRing> to the ground (overrides all other extrusion options)
number <DistanceAboveSurface> (Optional - default=0) defines an absolute altitude to offset the entire <LineString>, which is in addition to the Z coordinate which might be specified in each posList point
number <MaximumDisplayAltitude> (Optional - default=infinity) defines when the <PolygonFeature> will be visible as the camera zooms to different altitude levels
number <MiminumDisplayAltitude> (Optional - default=0) defines when the <PolygonFeature> will be visible as the camera zooms to different altitude levels
integer <Opacity> (Optional - default=255) defines the translucency, valid values are from 0-255, with 0 being transparent and 255 being opaque
boolean <Outline> (Optional - default=false) defines a link (local or remote) to an image to be mapped to the <PolygonFeature> requires ExtrudeHeight greater than zero
string; <AltitudeMode> (Optional - default=clampedtoground) defines where to postition the line. Set to "absolute", "clampedtoground" or "relativetoground".  Use "clampedtoground" to draw 2d polygons draped over the terrain.

integer <Opacity> (Optional - default=255) defines the translucency, valid values are from 0-255, with 0 being transparent and 255 being opaque

<LinearRing> (Required) defines the list of points to be used for the <PolygonFeature>. Points are seperated with spaces, and can be 2 or 3 coordinates, with X,Y,Z ordering (X:Longitude, Y:Latitude, Z:altitude(m))

<exterior>
	<LinearRing>
		<posList>
			-120,35,10000 -119,36,20000 -120,38,100000 -122,38,60000
		</posList>
	</LinearRing>
</exterior>

<FeatureColor> (Optional - default=Black) defines the color used for the <LineFeature> only used with there is no image-mapping

<FeatureColor>
	<Red>255</Red>
	<Green>100</Green>
	<Blue>0</Blue>
</FeatureColor>

<OutlineColor> (Optional - default=Black) defines the color used for the outline <LineFeature> only used when <Outline> is set to true

<OutlineColor>
	<Red>255</Red>
	<Green>100</Green>
	<Blue>0</Blue>
</OutlineColor>

Example

<?xml version="1.0" encoding="UTF-8"?>
<LayerSet Name="Polygon Features" ShowOnlyOneLayer="false" ShowAtStartup="true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="LayerSet.xsd">
	<PolygonFeature ShowAtStartup="true">
		<Name>Sample Polygon</Name>
		<AltitudeMode>RelativeToGround</AltitudeMode>
		<Extrude>true</Extrude>
		<ExtrudeHeight>20000</ExtrudeHeight>
		<ExtrudeUpwards>true</ExtrudeUpwards>
		<DistanceAboveSurface>0</DistanceAboveSurface>
		<MinimumDisplayAltitude>0</MinimumDisplayAltitude>
		<MaximumDisplayAltitude>5000000</MaximumDisplayAltitude>
		<exterior>
			<LinearRing>
				<posList>
					-120,35,10000 -119,36,20000 -120,38,100000 -122,38,60000
				</posList>
			</LinearRing>
		</exterior>
		<FeatureColor>
			<Red>255</Red>
			<Green>100</Green>
			<Blue>0</Blue>
		</FeatureColor>
		<Opacity>100</Opacity>
		<Outline>true</Outline>
		<OutlineColor>
			<Red>100</Red>
			<Green>100</Green>
			<Blue>100</Blue>
		</OutlineColor>
	</PolygonFeature>
</LayerSet>
JIRA Issues Macro: Data cannot be retrieved due to an unexpected error
  • No labels