Multi-Points

Overview

Geometric objects that are definied by two or more points create Paths (or Polylines) and Polygons in KML. They utilize the <Placemark> feature in combination with other elements, including style-types.

New KML: <color> <colorMode> <fill> <innerBoundaryls> <LinearRing> <LinearString> <LineStyle> <MultiGeometry> <outerBoundaryls> <outline> <Polygon> <PolyStyle> <tessellate> <width>

Tutorial

Creating Paths (Polylines)

(1) Create a path with three or more points over an area with elevated topography.
(2) Open the properties dialog box and change color, width and opacity.
(3) Copy the path's KML into a text editor. Observe that the KML actually defines a <Placemark> with coordinates defined within <LineString> rather than <Point>.
(4) Observe <Style>, <StyleMap> and <styleUrl> are also used in the same way as before, with the line's properties defined within <LineStyle>. Simplify this KML so there is one fixed style.
(5) Observe within <LineString> the use of <tessellate>. This allows the line to follow topography if <altitudeMode> is set to clampToGround (this is the default value with 0m altitude, so this element is not currently shown).
(6) Set <tessellate> to 0 and save file as flatline.kml.
(7) Open flatline.kml in Google Earth and compare to the line originally drawn in (1).

Path Locations and Lengths

The location of a path can edited by opening properties and then clicking and dragging the red point that appear in the viewer. The path can also be extended in length using right-click on a mouse. To delete sections left click to turn highlight a point (turns blue) blue and use the backspace.

Editing Paths

(8) Open the properties dialog box for flatline and adjust the altitude to 2000m, and check extend path to ground.
(9) Save as flatline.kml and open in a text editor
(10) Note that <extrude> and <altitudeMode> now appear under <LineString>
(11) Re-open the properties dialog and under color you will find there is an additional option for area. Change the area color, opacity and check the random box.
(12) Save, open in a text browser and identify the addition of the <PolyStyle> element with <color> and <colorMode> child elements.

MultiGeometry

Mutliple unconnected lines can be drawn as party of the same feature by using the container element <MultiGeometry>:


Creating and Editing Polygons

(13) Create a polygon.
(14) Change the altitude, line width, color and opacity, area color and opacity, and extend to ground.
(15) Save file as polygon.kml and open in a text editor.
(16) Observe how all the elements are familar except that <LineString> has been replaced by <Polygon> and <coordinates> is wrapped by <LinearRing> and <outerBoundaryls>.
(17) Under <PolyStyle> add <fill>0</fill>. Save file and open in Google Earth, and observe what has changed.
(18) Replace the <fill> element with <outline> Save file and open in Google Earth, and observe what has changed.

Creating a Hole in a Polygon

Holes can be created in polygons by defining coordinates for <innerBoundaryIs> in addition to the <outerBoundaryIs> values.

Example:


Exercises

(A) Build three different colored polygons to represent the GI, IARC and WRRB, and locate them correctly in Google Earth, similar to the Google campus example above.

(B) Create a path that can be used to tour one of your favourite destinations (e.g. The Grand Canyon). In your KML include a description bubble that specifies the best touring option settings for the viewer.