Boost logo

Geometry :

Subject: Re: [geometry] Support for geographic coordinate system
From: Adam Wulkiewicz (adam.wulkiewicz_at_[hidden])
Date: 2014-11-17 19:53:05


Barend Gehrels wrote:
> Adam Wulkiewicz wrote On 14-11-2014 12:33:
>> Since we already have bg::cs namespace, somehow related to the
>> reference system. We could reuse this scheme:
>> boost::geometry::rs::spheroid<>
> The common abbreviation is srs (spatial reference system), so as we
> get to that direction, I would certainly use that one. That would
> actually look quite good.
>> but should spheroid and sphere be included in reference systems
>> (namespace)? They're rather models describing the ref systems. Though
>> it's possible that we'd need a place for more code related to
>> reference systems, EPSGs, SRIDs, etc. so this code could be put
>> there. But then I'd put the models in:
>> boost::geometry::rs::model::sphere<>
>> boost::geometry::rs::model::spheroid<>
>> Or just reuse the namespace cs for this:
>> boost::geometry::cs::model::sphere<>
>> boost::geometry::cs::model::spheroid<>
>> which would be probably the most general choice. The question is:
>> could additional things be put in the bg::cs namespace?
> I think I would prefer the srs namespace.

Indeed srs is a better name than rs. Though I'm not sure that we should
use it. On the wikipedia
( there states:

A spatial reference system (SRS) or coordinate reference system (CRS) is
a coordinate-based local, regional or global system used to locate
geographical entities. A spatial reference system defines a specific map
projection, as well as transformations between different spatial
reference systems.
Spatial reference systems can be referred to using a SRID integer,
including EPSG codes (...)

AFAIU SRS is higher-level concept than sphere and spheroid models
representing a coordinate system. By using those models I'm not defining
any particular SRS since AFAIR SRS should also define other things like
units and the N/S W/E mapping, etc. The concept of SRS is bound closely
with geography/GIS and on this level I'd prefer to be domain-agnostic,
in other words be closer to mathematics. Newly added sphere/spheroid
represent a global system, not necesarily for geographical entities.

Does the above have some sense?


Geometry list run by mateusz at