[Qgis-user] QGIS Server Projection Problems
Hung,Emma [Ontario]
Emma.Hung at ec.gc.ca
Thu Oct 17 09:20:53 PDT 2013
I am running Ubuntu 12.04 with qgis (2.0.1), qgis-mapserver and
libapache2-mod-fcgid packages installed using apt-get install.
I am trying to serve up data from gml files to a WMS client (I've also
tried shape files). The source is in lat/lon EPSG:4326 projection, I've
specified this same projection for the project (or at least I believe I
have). Once I save the project I then use the .qgs file as my "mapfile"
for the qgis mapserver. When I compare the output from QGIS Server and
MapServer in my WMS client I observe that the projections do not match
(note the source is the same for both), I see the same distortion
whether I use gml or shape files as a source. I'm confident that the
result from MapServer is correct because it matches the original images
from the producing software. I've attached a screen shot to this email
to illustrate the distortion, the green areas are from Map Server and
the yellow are from QGIS Server.
Here's a snippet from the destinationsrs block:
<projections>1</projections>
<destinationsrs>
<spatialrefsys>
<proj4>+proj=longlat +ellps=WGS84 +datum=WGS84
+no_defs</proj4>
<srsid>3452</srsid>
<srid>4326</srid>
<authid>EPSG:4326</authid>
<description>WGS 84</description>
<projectionacronym>longlat</projectionacronym>
<ellipsoidacronym>WGS84</ellipsoidacronym>
<geographicflag>true</geographicflag>
</spatialrefsys>
</destinationsrs>
and here's the srs block:
<srs>
<spatialrefsys>
<proj4>+proj=longlat +ellps=WGS84 +datum=WGS84
+no_defs</proj4>
<srsid>3452</srsid>
<srid>4326</srid>
<authid>EPSG:4326</authid>
<description>WGS 84</description>
<projectionacronym>longlat</projectionacronym>
<ellipsoidacronym>WGS84</ellipsoidacronym>
<geographicflag>true</geographicflag>
</spatialrefsys>
</srs>
and the SpatialRefSys block:
<SpatialRefSys>
<ProjectCRSProj4String type="QString">+proj=longlat
+ellps=WGS84 +datum=WGS84 +no_defs</ProjectCRSProj4String>
<ProjectCrs type="QString">EPSG:4326</ProjectCrs>
<ProjectionsEnabled type="int">1</ProjectionsEnabled>
</SpatialRefSys>
The WMS client is re-projecting to suit its needs.
Please forgive me I'm not a GIS expert my background is computer science
and I work with research meteorologists so my grasp on geographic
projections is not great, mathematically I get what needs to be done but
I'm not familiar with all the lingo for describing them.
I'd appreaciate any insight you might have on this issue. I quite like
the WYSIWYG aspect of creating the map file and would love to use the
QGIS mapserver instead of MapServer, but if I can't fix this I'll have
to settle I suppose. Thank-you!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20131017/56e3606d/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: example2.png
Type: image/png
Size: 20892 bytes
Desc: example2.png
URL: <http://lists.osgeo.org/pipermail/qgis-user/attachments/20131017/56e3606d/attachment.png>
More information about the Qgis-user
mailing list