output -T geojson as WGS84 coordinates
This commit is contained in:
parent
bfca604ab5
commit
27da2a9c9e
2 changed files with 6 additions and 1 deletions
|
@ -269,7 +269,11 @@ int main(int argc, char** argv) {
|
|||
|
||||
auto l = shapeBuilder.shapeL(singleTrip);
|
||||
|
||||
o.print(l, util::json::Dict{{"ver", "new"}});
|
||||
// reproject to WGS84 to match RFC 7946
|
||||
for (auto& p : l) {
|
||||
p = util::geo::webMercToLatLng<double>(p.getX(), p.getY());
|
||||
}
|
||||
|
||||
o.flush();
|
||||
pstr.close();
|
||||
|
||||
|
|
|
@ -110,6 +110,7 @@ double Collector::add(const Trip* t, const Shape* oldS, const Shape& newS,
|
|||
gjout.print(oldL, util::json::Dict{{"ver", "old"}});
|
||||
oldLCut.insert(oldLCut.end(), oldL.begin(), oldL.end());
|
||||
}
|
||||
|
||||
for (auto newL : newSegs) {
|
||||
gjout.print(newL, util::json::Dict{{"ver", "new"}});
|
||||
newLCut.insert(newLCut.end(), newL.begin(), newL.end());
|
||||
|
|
Loading…
Reference in a new issue