HYPACK GML Support

HYPACK GML Support
By Bill Bergman
WHAT IS GML?
GML stands for Geographic Markup Language. It's purpose is to allow the transfer of
geographic information between systems in a standardized way. Following the markup
language craze, which has become so popular amongst file format types ( If you think I'm
kidding, google "List of XML markup languages" ), it is yet another format in the XML family.
More specifically, it defines an XML grammar for the encoding of geographic information.
The information that can be encoded includes, not only geographic objects and their
geometries, but also more abstract notions like coverages and observations.
GML PROBLEMS
The major problem with GML, of which in my opinion there are many, is that instead of being
an actual standard unto itself, it embraces the idea of an application schema. This is a
‘community of interest’ document which tells reading software how to interpret the objects
and data inside any particular GML document. So in the quest for flexibility, the standard is
mostly deferred to these schema files which makes GML, not a standard really, but more of a
stepping stone.
As a contrast, KML, Keyhole Markup Language, is an actual standard. This is the markup
language developed by Google to power its Google Earth™ application. The format may not
be as encompassing as GML in terms of content, but it is certainly well-defined which allows
software to be written in a complete fashion, rather than depending on a, possibly unknown,
extension in the form of a schema.
What all this means for the HYPACK® implementation is that it will extract Points, Lines and
Polygons from almost any GML file, but it will not manipulate the data as a higher level
feature (eg. a bridge, which could be tested for clearance or a rock, which should be detected
and avoided). What we can tell you about the geometry is the class of the object which
wraps it. This is a useful bit of data and leads us to the next topic of presentation.
PRESENTATION
Another deficiency of GML is the complete lack of presentation support. Again, unlike KML
which allows the encoding of presentation information in the form of colors, line styles, etc.,
GML delivers only coordinates. One's best hope is that the software has foreknowledge of
the appropriate application schema which might direct the display based upon attributes
attached to the objects wrapping the geometry. Good luck with that. In our software, we
provide a means of symbolizing a GML file based on the class name of an object and its
fundamental primitive type.
The GML Presentation Editor (Figure 1) works in a very similar fashion to the presentation
portion of the DG2 EDITOR. The notes in the diagram highlight the main portions of the
editor. It's use is quite simple and intuitive.
September / 2012
1
FIGURE 1. GML Presentation Editor
GML COORDINATES
In KML, the coordinates of geometry are defined by its standard to be in WGS84 Latitude
Longitude format. This is a well-known encoding which allows software to easily manipulate
the positions as required to, for instance, project to a local coordinate system.
In GML we are not so fortunate. What is given is a CRS ( coordinate reference system ) code
which is used as a look up entry point into a database of geographic information maintained
by the European Petroleum Survey Group. The group is actually now defunct but calling the
CRS value and EPSG code is still common. Software would then need to issue queries on
this relational database, hoping to extract the necessary values to plug into their own
geodetic formulas. The magic values are spread all over the place and the use of surrogate
names is common. Of course, to further complicate matters, any and every geometry entry in
a GML file can have its own code, leading to a hopeless mess for manipulating the data.
Given this situation, the HYPACK® software can offer little support to automatically convert
the source data into your local project’s geodesy settings. We do support the automatic
projection of GML data, if the CRS/EPSG code refers to WGS84. Beyond that, we treat the
data without conversion. We leave it to the user to know their projects and data and set the
appropriate geodesy settings. We will continue to try and improve our support over time as
we gain experience.
2