Feature request #17273
Respect coordinate system (CRS) when outputFormat=GeoJSON
Status: | Feedback | ||
---|---|---|---|
Priority: | Low | ||
Assignee: | - | ||
Category: | QGIS Server | ||
Pull Request or Patch supplied: | No | Resolution: | |
Easy fix?: | No | Copied to github as #: | 25171 |
Description
Following request returns correct coordinate system:
Add outputFormat=GeoJSON and wrong coordinate system is returned:
This doesn't happen in 2.14
History
#1 Updated by Richard Duivenvoorde about 7 years ago
Hi Henrik,
Officially Geojson is always in epsg:4326 / lat lon coordinates:
https://tools.ietf.org/html/rfc7946#page-12
And I see that QGIS reprojects your data nicely (both version gml and json fit exactly)
Not sure if that is the reason QGIS always returns it, but it could be the reason that the older QGIS followed the older spec (see the spec text).
I agree that sometimes it can be helpfull to have the original coordinates though... maybe discuss an optional switch?
Does geoserver still return different crs's?
#2 Updated by Giovanni Manghi about 7 years ago
- Status changed from Open to Feedback
#3 Updated by Henrik Uggla about 7 years ago
- Status changed from Feedback to Open
We are using Geoserver 2.11.0 (latest is 2.11.2) and it does return different crs's.
#4 Updated by René-Luc ReLuc about 7 years ago
To support different's CRSs in WFS, QGIS Server needs to implement WFS 1.1.0.
It's not a regression because, QGIS Server does not specify the CRS in the GeoJSON output.
And the QgsJSONUtils has been designed to strictly respect the GeoJSON ISO specification https://qgis.org/api/2.18/classQgsJSONUtils.html
So if you want that QGIS Server (and QGIS) can generate GeoJSON in an other CRSs, the QgsJsonUtils has to be updated and used in WFS 1.1.0 implemented in QGIS 3.
#5 Updated by Giovanni Manghi about 7 years ago
- Status changed from Open to Feedback
René-Luc ReLuc wrote:
To support different's CRSs in WFS, QGIS Server needs to implement WFS 1.1.0.
It's not a regression because, QGIS Server does not specify the CRS in the GeoJSON output.
And the QgsJSONUtils has been designed to strictly respect the GeoJSON ISO specification https://qgis.org/api/2.18/classQgsJSONUtils.html
So if you want that QGIS Server (and QGIS) can generate GeoJSON in an other CRSs, the QgsJsonUtils has to be updated and used in WFS 1.1.0 implemented in QGIS 3.
so this should be a feature request instead?
#6 Updated by Alessandro Pasotti over 6 years ago
- Priority changed from High to Low
- Tracker changed from Bug report to Feature request
- Subject changed from Qgis Server WFS returns wrong coordinate system when outputFormat=GeoJSON to Respect coordinate system (CRS) when outputFormat=GeoJSON
Changed to feature request with low priority.