16
ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach 10 04 65 D-63004 Offenbach [email protected]

ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

Embed Size (px)

Citation preview

Page 1: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

The Use of GML for the

Unified Definition of Boundary Polygons

byDieter Schröder

Deutscher WetterdienstPostfach 10 04 65

D-63004 Offenbach

[email protected]

Page 2: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Summary

Advantages: The approach is excellent!

• GML provide an easy and flexible possibility to define spatial geometries

• The definition of spatial geometries is very easy

• The close connection to XML allows an easy transfer of GML defined geometries between different IT-applications (GIS, data bases, self-written programs)

Problems: Details still in developement!

• The GML standard is still in fundamental motion

• Although it is downward compatible, basic elements has been set „depricated“.

• The connection of a GML geometry and the referenced coordinates is still a problem.

Page 3: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Introduction: What is GML?

• GML: Geography Markup Language

• GML based on XML: philosophy, basic structures, grammar

• GML can be regarded as a XML dialect for spatial information

• GML is vector oriented --> objekts are therefore resolution independent

• GML transports map content, and not displaying features

• GML objects can be linked to additional data/information

• GML objects can specify time contraints and reference points --> Definition of moving objects are possible

• GML defined data can be exchanged with any IT-system providing an XML interface

• Application of GML is focused on Internet based mapping tools Examples: NASA Web Map Server (http://viewer.digitalearth.gov) ESA Web Map Server (http://mapserv2.esrin.esa.it/map/wtf)

Page 4: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Introduction: GML structure

Elements

• A GML file consists of a collection of „Features“

• GML has „Feature elements“ which descripes phenomina in the real world

• Features contain subelements („properties“) which identify characteristics of a Feature

• Subelements can also be or contain Features Example: Feature „City“ have properties „cityMember (1 ... N)“ which contain Features like „River“, „Road“, ...

• GML definitions can contain links. An attribute identifier gml:id can be specified.

Conventions

• Feature_names (upper case)

• property_names (lower case)

Page 5: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Object hierachy of geometries:(complies with ISO 19107)

Page 6: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Coordinate Data (I)

• For spatial information, GML geometries relate to a coordinate reference system (CRS)

• The coordinate reference system (CRS) must be

- defined in GML

- link a so-called „well known system“ to the GML definition

• CRS indicates how the coordinates are to be interpreted

• CRS indicates also in which order the dimensions are quoted (N/E-, x/y-pairs)

• The coordinate of features are always properties which can be defined as:

(1) one coordinate tuple: pos

(2) a list of coordinate tuples: posList

(3) a defined or referenced point: pointProperty

Page 7: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Coordinate Data (II)

(1) <gml:pos> x1 y1 </gml:pos>

(2) <gml:posList srsName=... srsDimension=„2“ count=„2“> x1 y1 x2 y2 </gml:posList>

(3) <gml:pointProperty> <gml:Point gml:id=„p1“> <gml:pos> x1 y1 </gml:pos> </gml:Point> </gml:pointProperty>

<gml:pointProperty xlink:href=„p1“/>

Examples:

Page 8: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Feature:

defined by:

Example:

gml:LineString

(1) seqence of „pos“ or „pointProperty“(2) a „posList“

<gml:LineString> <gml:pos> x1 y1 </gml:pos> . . . . . . <gml:pos> xN yN </gml:pos></gml:LineString>

gml:LinearRing

--> additional condition xN yN = x1 y1

<gml:LineString> <gml:pos> x1 y1 </gml:pos> . . . . . . <gml:pos> x1 y1 </gml:pos></gml:LineString>

Feature: gml:Curve gml:Ring

Note: These elements are the bases for all GML geometries!!

Line and Area Definition

Page 9: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Surface Definition

GML surfaces are defined by certain surface elements or polygons

• Surface elements are: „Triangle“, „Rectangle“, „PolygonPatches“

• „Polygons“ consist of one or more „LinearRings“

• „Polygons“ can also have an „exterior“ or „interior“ property

Note: When a apropriate coordinate system is referenced the construction of a polygon will be no problem even if a pole is encompassed or a date line is crossed!

Page 10: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Surface Definition: Example

<gml:Polygon gml:id=“right_poly“>

<gml:exterior>

<gml:LinearRing>

<gml:pointProperty>

<gml:Point gml:id=„p01“>

<gml:pos> x1 y1 </gml:pos>

</gml:Point>

..

..

</gml:PointProperty>

</gml:LinearRing>

</gml:exterior>

</gml:Polygon>

right_poly

Page 11: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Surface Definition: Example<gml:Polygon gml:id=“left_poly“>

<gml:exterior>

<gml:LinearRing>

<gml:pos> x0 y0 </gml:pos>

<gml:pointProperty xlink:href“#p01“>

..

</gml:LinearRing>

</gml:exterior>

<gml:interior>

<gml:LinearRing>

<gml:posList> x1 y1 ... xN yN </gml:posList>

</gml:LinearRing>

</gml:interior>

</gml:Polygon>

left_poly

Page 12: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Compount Geometries (I)1. GeometricComplex a given number of element properties which can contain a geometric primitive

2. Geometric Composites (recommended) are restricted to a combination of a particular form

Example: <gml:CompositeSurface>

<gml:surfaceMember>

<gml:Polygon>

..

</gml:Polygon>

</gml:surfaceMember>

<gml:surfaceMember>

...

...

</gml:CompositeSurface

Page 13: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Compount Geometries (II)

3. Geometric Aggregates (recommended)

can also combine non-related geometric elements

Defined aggregates are: MultiGeometry <---> geometryMember

MultiPoint <---> pointMember

MultiCurve <---> curveMember

MultiSurface <---> surfaceMember (recommended)

Page 14: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Extent of Features• Self definition of a feature:

complexType name=... <complexContent> <extention base=„gml:AbstractFeatureType“>

• Additional spatial information can be attached with: extentOf / multiExtentOf

• A maximum boundary can be specified with the „boundedBy“ property (recommended)

<gml:boundedBy> <lowerCorner> xl yl </lowerCorner> <upperCorner> xu yu </upperCorner> </gml:boundedBy>

• Note: If an appropriate earth coordinate system is referenced, the upper corner can have smaller values than the lower corner (poles encompassed)!

• An all-inclusive boundary of several features can be obtrained using „Envelope“ feature <gml:Envelope srsName=„urn ...“ srsDimension=„2“> (recommended)

Page 15: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Coordinate Reference Systems (CRS)

• GML requires a CRS, otherwise all coordinate interpretation are ambigous

• The reference to coordinates is achieved by a: (1) so-called „well-known“ CRS (2) definition of an own-purpose CRS on the basis of ISO 19111

• The reference to a „well-known“ CRS can be done with the „srsName“ atrribute in the feature „gml:AbstractGeometryType Example: <gml:Point srsName=„urn:EPSG:geographicCRS:4326“>

• „urn:EPSG:geographicCRS:4326“ lead to a definition of a well-known CRS specified by the European Petroleum Survey Group

• „urn:EPSG:geographicCRS:4326“ uses latitude/longitude and is equal to WGS84

• The World Geodetic System 1984 is the basis of GPS data

• For a definition of an own CRS you need: (1) Mathematical description of the coordinate system (coordinates <-->points) (2) Position of the origin (3) Orientation of the axis (4) Scale (5) Transformation rules

Page 16: ET-IDM Geneva 1st - 3rd September 2004 The Use of GML for the Unified Definition of Boundary Polygons by Dieter Schröder Deutscher Wetterdienst Postfach

ET-IDM Geneva 1st - 3rd September 2004

Recommendations 1. For coordinate reference a well-known coordinate systems should be used preferably. WMO recommend the adaption of the „urn:EPSG:geographicCRS:4326“.

2. CRS are to be specified using GML only if they are not well-known

3. WMO has to define a specified schema document containing the definitions for several features

4. Objects for the definiton of boundary polygons should be restricted in the WMO.

5. For the definition of a simple boundary polygon in earth coordinates, only the GML object „Polygon“should be used

6. To define a multiple connected area the CompositeSurface feature should be used.

7. Non connected multiple areas should be defined with „MultipleSurface“ and „FeatureCollection“.

8. For computation and presentation purpose „boundedBy“ and „Envelope“ can be used.

9. For assignment of additional information (spatial weather phenomina) „extentOf“ and „multiExtentOf“ aliases should be used.