"Seegrid will be due for a migration to confluence on the 1st of August. Any update on or after the 1st of August will NOT be migrated"

GML Geometry Components

Contents

Related pages



Schema documents


Introduction

Most geographic features have one or more properties whose values are geometric - their position is a Point, their shape will be an extensive geometry such as a Polygon or Solid, etc. Indeed the geometric characteristics of geographic objects loom so large that traditional GIS systems often modelled features as "geometries that also happen to carry other attributes".

The ISO/OGC model inverts this, putting the horse back before the cart if you like, and treats "conceptual objects" as primary (road, house, mine, volcano, truck, tenement etc). Geometries appear in an important but subsidiary role, as the values of specific, semantically meaningful, properties. Thus a "Point" may be found within the description of a particular feature, but in encodings based on GML, its role in relation to that feature is explicit: centroid, corner, mail-box-position, etc.

In order to support the description of a rich set of potential geometric characteristics, we need models and encodings for a rich set of geometries.

GML Geometry Components

Geometry components for XMML are primarily supplied by the six GML geometry schema documents. GML geometry is fully documented in the GML specification from Open GIS Consortium, currently undergoing standardisation through ISO TC 211, and expected to appear in 2004 or 2005 as ISO 19136. The GML schema provides an XML implementation of most of the model described in ISO 19107 Geographic Information: Spatial Schema.

While the GML geometry schema is thorough and rigorous, the very literal implementation of the ISO 19107 model can lead to a rather cumbersome structure.

For example, there are effectively only two concrete elements in GML for all solid geometries: gml:Solid and gml:CompositeSolid. A CompositeSolid has a set of solidMember components, each of which refers to a Solid or a nested CompositeSolid. A Solid is defined as an extensive 3-D geometry primitive, optionally bounded by one exterior Surface, and any number of interior Surface components. Each of these Surface components has patches containing a set of SurfacePatch components. These come in a variety of forms, often based on the PolygonPatch which has one (optional) exterior Ring and any number of interior Ring components. The simple LinearRing components are defined by a sequence of positions or Points. However, general Ring components have curveMembers containing a sequence of Curve components, which in turn have segments containing a sequence of CurveSegment components, of which there are many possible forms, including Arc, BSpline, Geodesic, and LineStringSegment. Finally, the various curve segment objects are all defined using nodes, described in pos or posList components, or referring to Point objects which have pos properties.

A hierarchy of geometry objects is exposed in the model and reflected in the encoding, with clear distinction made between objects of various dimensionalities and levels of composition: viz. the solid (primitive or composite), the surface(s) bounding the solid, the patches composing the surface, the rings bounding the patches, the curve segments composing the rings, and finally the nodes used to define the curves. This approach ensures that operations carried out on the solids produce unambiguous results, and is likely to be safest for transfer of information between parties who have a limited understanding of each other's domain.

Geometry requirements in Geoscience

However, when working within an application domain, it is common to find that, alongside the standard feature catalogue, there will be agreement on a set of common geometries. These occur sufficiently often that streamlined models are used, in which certain conventions (e.g. regarding the order of nodes defining higher order objects) allow one or more layers of the hierarchy to be collapsed. These can result in a more compact encoding.

Within engineering and the geosciences this applies in particular to the treatment of solid geometry. Solid models are usually
  • composites of regular shapes like hexahedral bricks, wedges, pyramids and tetrahedra, or
  • bounded by triangulated surfaces.

Other aspects of conventional practice need to be considered. Complex surfaces are almost always represented by triangulations. Irregular 1-D coordinate systems are commonly used during data acquisition (position given as distance offset along a borehole, or time offset along a flight-line).

Thus, for XMML, as well as using the standard GML geometry components, we also define compact forms for several commonly occurring geometries.

In the following sections we first provide a brief overview of the GML components likely to be of greatest interest for XMML. This is followed by a more thorough description of the specialised XMML geometry components.


GML Geometry

This section briefly describes the abstract (non-instantiable) and non-abstract (instantiable) geometry objects provided by the GML geometry schema.

Top level components

Models from GmlSchemaRepository:base/geometryBasic0d1d.xsd, GmlSchemaRepository:base/geometryAggregates.xsd and GmlSchemaRepository:base/geometryComplexes.xsd.

Model

Geometry.png

  • GML Geometry class hierarchy:
    GML Geometry class hierarchy

GeometricComplex.png

Explanation

GML Geometries are implemented as first-class objects, with "identity" (see LabelsAndHandles). They all carry the Standard Object Properties (metaDataProperty [0..*], description [0..1], name [0..*] as sub-elements, and id [0..1] as an XML attribute).

Every geometry object may also carry an srsName attribute, whose value is a URI that identifies the spatial reference system (usually a coordinate reference system (CRS)) used for positions in the geometries. A complete description of the CRS may be given in a GML CoordinateReferenceSystems document. However, since the description is only loosely coupled with a geometry instance, through a URI reference, it may be provided from another source, which may be authoritative (e.g. EPSG) or informal.

Because the complete definition of the coordinate reference system may not be immediately available, the CRS reference may optionally be augmented with a group of attributes that summarise the most important aspects of the system: its dimension (usually 2 or 3), the axisLabels and uomLabels which are space separated lists of terms in axis order.

Note that in a GML (or XMML) instance document, unless overridden by a local declaration, all geometries inherit the Spatial Reference System used by the value of the gml:boundedBy property of the containing feature or feature collection.

At the top of the hierarchy, the elements
  • gml:_Geometry
  • gml:_GeometricPrimitive
  • gml:_GeometricAggregate
  • gml:GeometricComplex
each act as the head of a substitution group.

The first three share the same basic content model.

gml:GeometricComplex is non-abstract allowing it to appear directly in instance documents. It carries one or more element properties, each of which contains or refers to a member of the gml:_GeometricPrimitive substitution group (see GmlProperty).

  • GML Geometry primitives hierarchy:
    GML Geometry primitives hierarchy

0-D geometry components

Models from GmlSchemaRepository:base/geometryBasic0d1d.xsd.

Model

Point.png

MultiPoint.png

Explanation

The element for a 0-D geometry primitive is
  • gml:Point

It extends the basic gml:_Geometric Primitive with a pos property which has type="gml:DirectPositionType".

The element for an aggregate of 0-D geometry objects is
  • gml:MultiPoint

It follows a standard pattern for geometric aggregates in GML, with a sequence of pointMember properties each referring to one gml:Point, or a pointMembers property containing several gml:Point elements.

gml:DirectPositionType has a simpleContent model that contains a space separated sequence of numbers representing components of a coordinate. Since simpleContent models are not displayed effectively as XML Spy diagrams, the text version of the schema is shown:

  <complexType name="DirectPositionType">
    <simpleContent>
      <extension base="gml:doubleList">
        <attributeGroup ref="gml:SRSReferenceGroup"/>
      </extension>
    </simpleContent>
  </complexType>

  <attributeGroup name="SRSReferenceGroup">
    <attribute name="srsName" type="anyURI" use="optional"/>
    <attribute name="dimension" type="positiveInteger" use="optional"/>
    <attributeGroup ref="gml:SRSInformationGroup"/>
  </attributeGroup>

  <attributeGroup name="SRSInformationGroup">
    <attribute name="axisLabels" type="gml:NCNameList" use="optional"/>
    <attribute name="uomLabels" type="gml:NCNameList" use="optional"/>
  </attributeGroup>

gml:DirectPositionListType is provided to allow a set of coordinates to be recorded in compact form. A count attribute is provided in addition to the standard attributes, which may be used to indicate the number of positions encoded in the list.

  <complexType name="DirectPositionListType">
    <simpleContent>
      <extension base="gml:doubleList">
        <attributeGroup ref="gml:SRSReferenceGroup"/>
        <attribute name="count" type="positiveInteger" use="optional"/>
      </extension>
    </simpleContent>
  </complexType>

gml:pos and gml:posList elements, using these type definitions, are declared globally for convenience.

1-D geometry components

Models from XmmlCVS:gml/base/geometryBasic0d1d.xsd, XmmlCVS:gml/base/geometryPrimitives.xsd, XmmlCVS:gml/base/geometryAggregates.xsd, XmmlCVS:gml/base/geometryComposites.xsd.

Model

LineString.png

Arc.png

CompositeCurve.png

  • GML Curves:
    GML Curves

Explanation

Elements for 1-D geometry primitives in the substitution group headed by gml:_Curve include:
  • gml:LineString
  • gml:Curve
  • gml:OrientableCurve

Elements for 1-D geometry components in the substitution group headed by gml:_CurveSegment include:
  • gml:ArcByCenterPoint
  • gml:CircleByCenterPoint
  • gml:ArcString
  • gml:Arc
  • gml:Circle
  • gml:ArcStringByBulge
  • gml:ArcByBulge
  • gml:BSpline
  • gml:Bezier
  • gml:Clothoid
  • gml:CubicSpline
  • gml:GeodesicString
  • gml:Geodesic
  • gml:LineStringSegment
  • gml:OffsetCurve

Each of these adds the necessary set of nodes and other properties to allow the object to be fully described.

Elements for 1-D geometry aggregates include:
  • gml:MultiCurve

Elements for 1-D geometry complexes include:
  • gml:CompositeCurve

2-D geometry components

Models from GmlSchemaRepository:base/geometryBasic2d.xsd, GmlSchemaRepository:base/geometryPrimitives.xsd, GmlSchemaRepository:base/geometryAggregates.xsd, GmlSchemaRepository:base/geometryComposites.xsd.

Model

Surface.png

PolygonPatch.png

LinearRing.png

  • GML Surfaces:
    GML Surfaces

Explanation

Elements for 2-D geometry primitives in the substitution group headed by gml:_Surface include:
  • gml:Polygon
  • gml:Surface
  • gml:PolyhedralSurface
  • gml:TriangulatedSurface
  • gml:Tin

Elements for 2-D geometry components in the substitution group headed by gml:_SurfacePatch include:
  • gml:PolygonPatch
  • gml:Rectangle
  • gml:Triangle
  • gml:ParametricCurveSurface
  • gml:GriddedSurface
  • gml:Cone
  • gml:Cylinder
  • gml:Sphere

Elements for 2-D geometry components in the substitution group headed by gml:_Ring include:
  • gml:Ring
  • gml:LinearRing

Each of these adds the necessary set of nodes and other properties to allow the object to be fully described.

Elements for 2-D geometry aggregates include:
  • gml:MultiSurface

Elements for 2-D geometry complexes include:
  • gml:CompositeSurface

3-D geometry components

Models from GmlSchemaRepository:base/geometryPrimitives.xsd, GmlSchemaRepository:base/geometryAggregates.xsd, GmlSchemaRepository:base/geometryComposites.xsd.

Model

Solid.png

* GML Solids:
GML Solids

Explanation

Elements for 3-D geometry primitives in the substitution group headed by gml:_Solid include:
  • gml:Solid

Elements for 3-D geometry aggregates include:
  • gml:MultiSolid

Elements for 3-D geometry complexes include:
  • gml:CompositeSolid

Vector

A model for representing a spatial vector is provided, implemented as gml:VectorType, which is used by the global element gml:vector. This has a simpleContent model identical to gml:DirectPositionType (see #0_D_geometry_components), consisting of a list of doubles representing the components of the vector, with the coordinate reference system indicated using the standard srsName attribute (see #Top_level_components).

Implicit geometry - grids

Model from GmlSchemaRepository:base/grids.xsd

Model

Grid.png

Explanation

A model for spatial grids is described in ISO 19123 Geographic Information: Coverage geometry and Schema. The basic definition of a grid is as follows:

A grid is a network composed of two or more sets of curves in which the members of each set intersect the members of the other sets in a systematic way. The curves are called grid lines; the points at which they intersect are grid points, and the interstices between the grid lines are grid cells.

The most common case is the one in which the curves are straight lines, and there is one set of grid lines for each dimension of the grid space. In this case the grid cells are parallelograms or parallelepipeds. In its own coordinate system, such a grid is a network composed of two or more sets of equally spaced parallel lines in which the members of each set intersect the members of the other sets at right angles. It has a set of axes equal in number to the dimension of the grid. It has one set of grid lines parallel to each axis. The size of the grid is described by a sequence of integers, in which each integer is a count of the number of lines parallel to one of the axes. There are grid points at all grid line intersections. The axes of the grid provide a basis for defining grid coordinates, which are measured along the axes away from their origin, which is distinguished by having coordinate values of 0. Grid coordinates of grid points are integer numbers. The axes need to be identified to support sequencing rules for associating feature attribute value records to the grid points.

A grid may be defined in terms of an external coordinate reference system. This requires additional information about the location of the gridís origin within the external coordinate reference system, the orientation of the grid axes, and a measure of the spacing between the grid lines.

... the term grid cell refers to the cell bounded by the grid lines that connect the grid points. [This should be clearly distinguished from the sample cell, which] ... refers to the observed or measured space surrounding a sample point."

The gml:Grid adds the following properties to the gml:AbstractGeometryType content model:
  • limits whose value is a GridEnvelope containing low and high properties each comprising an integer list
  • a list of axisName elements providing labels for the axes
Note that the limits of a standard (unrectified) grid are given in grid-index coordinates. The standard set of XML attributes providing information describing a coordinate reference system is inherited from gml:AbstractGeometryType. This includes srsDimension which defines the dimensionality of the grid.

The gml:RectifiedGrid ties the grid to a real-world coordinate reference system using the following properties:
  • origin is a gml:Point in the real world corresponding to the location of the grid point with zero index coordinates
  • a list of offsetVector elements describing the increment vector along each of the axes.

Geometry property components

Models from GmlSchemaRepository:base/geometryBasic0d1d.xsd, GmlSchemaRepository:base/geometryBasic2d.xsd, GmlSchemaRepository:base/geometryPrimitives.xsd, GmlSchemaRepository:base/geometryAggregates.xsd, GmlSchemaRepository:base/geometryComposites.xsd.

Model

GeometryPropertyType.png

PointPropertyType.png

solidProperty.png

Explanation

For almost all geometry objects, an associated model (XML Schema complex type) for a property whose value is an object of this type is available. These follow the standard GmlProperty model as shown: the GeometryPropertyType is a model that contains either a single Geometry object of the appropriate type, or uses an xlink:href attribute to carry the handle of a geometry object described elsewhere.

The normal use of these XML Schema complex type definitions is to provide the model for a property with a meaningful name, for example:

<element name="mailboxPosition" type="gml:PointPropertyType"/>

However, in some cases a global element for a generic property of this type is also provided, such as solidProperty shown here.

Feature types based primarily on geometry properties are described in GeometryBasedFeatures.


XMML Geometry

See XmmlGeometry

Topic attachments
I Attachment Action Size Date Who Comment
gmlCurves.PNGPNG gmlCurves.PNG manage 12.6 K 19 May 2005 - 17:22 SimonCox GML Curves
gmlGeometry.PNGPNG gmlGeometry.PNG manage 18.6 K 19 May 2005 - 17:21 SimonCox GML Geometry class hierarchy
gmlPrimitives.PNGPNG gmlPrimitives.PNG manage 12.1 K 19 May 2005 - 17:22 SimonCox GML Geometry primitives hierarchy
gmlSolids.PNGPNG gmlSolids.PNG manage 3.5 K 19 May 2005 - 17:23 SimonCox GML Solids
gmlSurfaces.PNGPNG gmlSurfaces.PNG manage 6.0 K 19 May 2005 - 17:22 SimonCox GML Surfaces
Topic revision: r23 - 28 Oct 2013, SimonCox
 

Current license: All material on this collaboration platform is licensed under a Creative Commons Attribution 3.0 Australia Licence (CC BY 3.0).