-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Coordinate axis order in northing/easting (Y/X) in WFS/GML #16
Comments
Looks like missing functionality. We just render the coordinates in the order |
Another factor here might be the used Django version and GDAL version. As of GDAL 3, the axis ordering was changed. Django 3.1 and later have support for that. In from django.contrib.gis.gdal import AxisOrder, SpatialReference
from gisserver.geometries import CRS
# Define the actual GDAL backend yourself, so the CRS object will use that:
gk25fin = CRS("EPSG:3879", backend=SpatialReference(3879, srs_type="epsg", axis_order=AxisOrder.AUTHORITY))
# Pass the CRS object to the feature type:
feature_types = [
FeatureType(
...,
crs=gk25fin,
other_crs=[..., gk25fin], # or this one.
)
] The rest of the code really just reads what GDAL will provide (like @lbam mentioned). For some background info, see: Hope this helps! and bye the way, we love that you guys started using this project too! (and for that matter completely extended it as well, exactly as the design intended). |
Well, atleast does not work like this, any ideas? I will dig in further soonish anyways...
|
Well, I gave up and decided to just overwrite a couple of more functions from |
btw. do you consider this as a feature or a bug? |
My project for City of Helsinki uses coordinate reference system EPSG:3879. We have a problem with latitude and longitude axis order in WFS GML output when using
django-gisserver
version1.2.4
.WFS 2.0.0 (with GML 3.2) should respects the axis order defined by the EPSG definition (unlike WFS 1.0.0 which is always easting/northing or (X,Y)). EPSG:3879 defines coordinate axis order as northing/easting (Y,X).
For query
<server url>/wfs/?SERVICE=WFS&VERSION=2.0.0&REQUEST=GetFeature&TYPENAMES=signpost&OUTPUTFORMAT=application/gml+xml&srsName=urn:ogc:def:crs:EPSG::3879
we are expecting:where
6673364.2700978
is latitude (Y) and25494172.7053077
is longitude (X).However, the actual result has invert latitude and longitude:
Do I have something wrong in my configuration? Or is this a missing feature or bug in
django-gisserver
?The text was updated successfully, but these errors were encountered: