Modify

Opened 8 years ago

Closed 7 years ago

Last modified 6 years ago

#10770 closed enhancement (fixed)

[Patch] save coordinates in current map projection

Reported by: TobWen Owned by: simon04
Priority: normal Milestone: 15.10
Component: Core Version:
Keywords: Cc:

Description

Since JOSM supports multiple map projections with the plugin "proj4j" and since it supports output in GeoJSON and GPX, it would be nice to export coordinates in the current map projection.

When working in EPSG:31466, coordinates get transformed back to EPSG:4326 on export. Since the transformation isn't perfect, errors are growing. Sure, that's not important for OSM, but JOSM can also be used outside of OSM.

GeoJSON, GPX and other formats support different map projects, so it would be nice to see an expert settings to switch from geographic coordinates to map coordinates.

Attachments (2)

10770.patch (9.4 KB) - added by simon04 7 years ago.
10770-2.patch (961 bytes) - added by Larry0ua 6 years ago.
CRS name to the correct place in geojson

Download all attachments as: .zip

Change History (9)

comment:1 Changed 8 years ago by stoecker

Regarding the errors it does not help, as JOSM always uses geographics coordinates. Different projections are only used for display. But the idea in itself may have other benefits.

comment:2 in reply to:  1 Changed 8 years ago by skyper

Replying to stoecker:

Regarding the errors it does not help, as JOSM always uses geographics coordinates. Different projections are only used for display. But the idea in itself may have other benefits.

Like the problems with tool functions (e.g. create circle,align etc.) ?

Changed 7 years ago by simon04

Attachment: 10770.patch added

comment:3 Changed 7 years ago by simon04

Milestone: 15.10
Owner: changed from team to simon04
Summary: save coordinates in current map projection[Patch] save coordinates in current map projection

attachment:10770.patch adds a *.proj.geojson exporter which writes the GeoJSON file with the currently set map projection. See http://geojson.org/geojson-spec.html#named-crs for the CRS specification in GeoJSON.

comment:4 Changed 7 years ago by simon04

Resolution: fixed
Status: newclosed

In 8813/josm:

fix #10770 - GeoJSON export: allow to save coordinates in current map projection

Adds a *.proj.geojson exporter which writes the GeoJSON file with the currently set map projection.

comment:5 Changed 6 years ago by Larry0ua

Hi,

There is a problem with the CRS field, it does not comply with the geojson spec.
Spec says: A non-null CRS object has two mandatory members: "type" and "properties".
This CRS object should look like: {"type":"name", "properties":{"name":"EPSG:4326"}}

See http://geojson.org/geojson-spec.html#coordinate-reference-system-objects for examples.

Changed 6 years ago by Larry0ua

Attachment: 10770-2.patch added

CRS name to the correct place in geojson

comment:6 in reply to:  5 Changed 6 years ago by simon04

Replying to Larry0ua:

There is a problem with the CRS field, it does not comply with the geojson spec.

Please make sure to reopen tickets when there are sill problems. Otherwise – as in this case – further comments are overlooked. Fixed in #12803.

comment:7 Changed 6 years ago by simon04

See also #13358: GeoJSON as in RFC 7946 no longer permits projections other than WGS84.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain simon04.
as The resolution will be set.
The resolution will be deleted.

Add Comment


E-mail address and name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.