[Mapserver-users] WMS client - multiple entries in "wms_srs"
Daniel Morissette
dmorissette at dmsolutions.ca
Wed Feb 25 07:49:16 PST 2004
Havard Tveite wrote:
> Using recent versions of Mapserver CVS, Proj.4, ... I am a little
> confused as to the the use of "wms_srs" in the METADATA of a WMS-layer.
>
> LAYER
> CONNECTIONTYPE WMS
> METADATA
> "wms_srs" "EPSG:4326 EPSG:32633 EPSG:27394 EPSG:4267 EPSG:4269"
> ...
>
> It seems to me that the first entry on the "wms_srs" list is
> always choosen by Mapserver when doing the WMS request.
>
> I thought that the point of having a list in "wms_srs" was that
> Mapserver could choose among these projections depending on the
> projection of the output map.
> This way, raster reprojection could in many cases be avoided,
> producing nicer output maps.
>
> What is the point of having a list of projections in "wms_srs"?
> Is it for future use?
>
That's right, the wms_srs contains a list of SRS supported by the remote
WMS server, and MapServer will choose the one that matches the map
output projection if it can. If it can't find a match, then it falls
back on using the first one and reprojects the raster image that it gets
from the remote WMS.
If the first one is always used, it could be that the output map
projection doesn't match any of the EPSG codes that are in your list.
Also note that MapServer can't do reverse lookups of EPSG numbers, so if
you define your map's output projection using the native PROJ parameters
(e.g. "proj=..." "lat_0=..."lon_0= ....) then MapServer won't be able to
match that to an EPSG code: you have to use "init=epsg:xxxx" as your
projection definition.
Of course there is always the possibility that a bug was introduced in
the recent code???
Daniel
--
------------------------------------------------------------
Daniel Morissette dmorissette at dmsolutions.ca
DM Solutions Group http://www.dmsolutions.ca/
------------------------------------------------------------
More information about the MapServer-users
mailing list