Rethinking CRS
From GeoJSON
This is proposed new language for the CRS section of the spec (currently at draft version 5).
See also http://lists.geojson.org/pipermail/geojson-geojson.org/2008-March/000366.html
- Coordinate Reference Systems: The coordinate reference system (CRS) of a GeoJSON object is determined by its "crs" member. If an object has no "crs" member, its parent object's "crs" member may be acquired. If no CRS can be so acquired, the default CRS shall apply to the GeoJSON object.
- Default coordinate reference system: The default is a geographic coordinate reference system, using the WGS84 datum, and with longitude and latitude units of decimal degrees. In many cases, the default is sufficient: when this is true, it is recommended that the CRS object not be included.
- The "crs" member: The value of a member named "crs" must be an object (referred to as the CRS object below).
- The CRS object: A CRS object has 2 mandatory members: "type", and "properties".
- The "type" member: The value of this required member must be a string, indicating one of the 2 types of CRS objects: "name" or "link".
- The "properties" member: The value of this required member must be an object.
- CRS object types: There are 2 types of CRS objects.
- Named: A CRS object may indicate a coordinate reference system by name. The value of its "properties" member must be an object containing a "name" member. The value of that "name" member must be a string identifying a coordinate reference systems. OGC CRS URNs such as "urn:ogc:def:crs:OGC:1.3:CRS84" shall be preferred over legacy identifiers such as "EPSG:4326".
- Example:
"crs": {"type": "name", "properties": {"name": "urn:ogc:def:crs:OGC:1.3:CRS84"}}
- Example:
- Linked: A CRS object may link to CRS parameters on the Web. In this case the value of its "properties" member must be a Link object (see below).
- The Link object: A link object has 1 required member: "href", and 1 optional member: "type". The link object is similar to Atom/HTML/RSS links.
- The "href" member: The value of this required member must be a dereferenceable URI.
- The "type" member: The value of this optional member must be a string that hints at the format used to represent CRS parameters at the provided URI. Suggested values are: "proj4", "ogcwkt", "esriwkt", though others can be used.
- Example:
"crs": {"type": "link", "properties": {"href": "http://example.com/crs/42", "type": "proj4"}}
- The Link object: A link object has 1 required member: "href", and 1 optional member: "type". The link object is similar to Atom/HTML/RSS links.
- Named: A CRS object may indicate a coordinate reference system by name. The value of its "properties" member must be an object containing a "name" member. The value of that "name" member must be a string identifying a coordinate reference systems. OGC CRS URNs such as "urn:ogc:def:crs:OGC:1.3:CRS84" shall be preferred over legacy identifiers such as "EPSG:4326".