Re: [mapserver-users] Mapserver WMS Reprojection

2013-05-20 Thread Rahkonen Jukka
Hi,

The Web Mercator projection is in meters too and your map will be switched off 
also with EPSG:27700 if you zoom far enough. Due to differences in projection 
settings the turn on/off may not happen in exactly same visible scale.  Play 
with the MAXSCALEDENOM value and perhaps you will find something that works for 
both of your projections.  If not, you can always copy the whole LAYER with a 
different name and edit the new layer to be optimal for OpenLayers.

-Jukka Rahkonen-

Donald Kerr wrote:
 
 Jukka,
 
 Got it! DEBUG 5 spotted the error:
 
 Skipping layer (CME) because LAYER.MAXSCALE is too small for this MAP
 scale
 
 I have the following:
 
 MINSCALEDENOM 1
 MAXSCALEDENOM 36000
 SYMBOLSCALEDENOM 24000
 
 If I comment them out then all is well and the required image is created and
 served.
 
 Now, the issue would appear to be that these figures are relevant to 27700
 and work with that in metres but do not work with 900913 which I assume is
 in degrees. The request SRS for a WMS is controlled by Openlayers so this is
 fixed as 90013 and I do have the map set for metres. The BBOX must be sent
 from Openlayers in degrees so I am think that this is where the problem is.
 Maybe I cannot use MAXSCALEDENOM in these circumstances where I need
 to serve in two projections.
 
 Many thanks.
 
 Regards,
 
 Donald
 
 
 
 -Original Message-
 From: Rahkonen Jukka [mailto:jukka.rahko...@mmmtike.fi]
 Sent: 20 May 2013 05:53
 To: Donald Kerr; mapserver-users@lists.osgeo.org
 Subject: Re: [mapserver-users] Mapserver WMS Reprojection
 
 Hi,
 
 I do not see obvious error and the 900913 BBOX hit UK somewhere in
 Scotland so I guess that you have data there. I was thinking that the fake
 900913 code is perhaps not included in the EPSG file and you should use
 EPSG:3785 instead but that case that would propably lead to some error
 message. Have still a try with 3785, and add DEBUG 5 into your layer setting
 and see what you get into your MS_ERRORFILE.
 
 -Jukka Rahkonen-
 
 
 Donald Kerr wrote:
 
  Slight mistake below; the projection definition in the layer is as
  follows with epsg in lowercase as I am led to believe that it should
  be
 so:
  init=epsg:27700
 
 -Original Message-
 From: mapserver-users-boun...@lists.osgeo.org
 [mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Donald Kerr
 Sent: 19 May 2013 20:36
 To: mapserver-users@lists.osgeo.org
 Subject: [mapserver-users] Mapserver WMS Reprojection
 
  Hi List,
 
  I am trying to reproject a WMS request from 27700 (UK Ordnance Survey)
  to
 900913 (OSM OpenStreetMap) without success. There no issue with the map
 file map or layer definitions in terms of serving up the WMS in 27700 but
 reprojection seems to fail. There appears to be very little online and I 
 cannot
 find a solution; hence this request for help or advice.
 
  Relevant parts of map file (some parts removed):
 
 PROJECTION
 init=epsg:27700
 END
 
 WEB
 METADATA
 wms_title My WMS
 wms_onlineresource  http://localhost/mapserver/mapserv.asp?;
 wms_srs EPSG:27700  EPSG:900913
 wms_enable_request *
 wms_abstract My WMS
 wms_extent 0 0 67 123
 wms_feature_info_mime_type text/plain
 wms_feature_info_mime_type text/html
 wms_feature_info_mime_type application/vnd.ogc.gml #
 info_format=application/vnd.ogc.gml
 ..
 
 Layer:
 
 METADATA
 wms_title CME
 wms_extent 0 0 67 123
 #wms_srs EPSG:27700 EPSG:900913
 wms_include_items all # No spaces
 gml_include_items all # No spaces
 gml_featureid ID
 END
 
 PROJECTION
 init=EPSG:27700
 END # PROJECTION
 
  Openlayers request:
 
  http://maps1/cgi-
 bin/mapserv.exe?MAP=D:\MyMapFile.mapLAYERS=CMETRANS
  PARENT
 =TRUEFORMAT=pngSERVICE=WMSVERSION=1.1.1REQUEST=GetMap
 STYLES=SRS=EPSG%3
 A900913BBOX=-484682.60504583,7512726.3043776,-
 415889.27960147,7547122.96709
 97WIDTH=900HEIGHT=450
 
  The result is a transparent image with no data showing. :( The same
  map file
 works correctly and serves an image if used with Openlayers and a map on
 EPSG 27700 so it's pointing at the reprojection of the BBOX maybe.
 
  What am I doing wrong? Any help greatly appreciated.
 
  Many thanks.
 
  Regards,
 
 Donald
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
 -
 No virus found in this message.
 Checked by AVG - www.avg.com
 Version: 2013.0.3336 / Virus Database: 3162/6338 - Release Date: 05/19/13
 
 ___
 mapserver-users mailing list
 mapserver-users@lists.osgeo.org
 http://lists.osgeo.org/mailman/listinfo/mapserver-users
 
 
 -
 No virus found in this message.
 Checked by AVG - www.avg.com
 Version: 2013.0.3336 / Virus Database: 3162/6338 - Release Date: 05/19/13
 

___
mapserver-users mailing list

[mapserver-users] Mapserver WMS Reprojection

2013-05-19 Thread Donald Kerr
Hi List,

I am trying to reproject a WMS request from 27700 (UK Ordnance Survey) to
900913 (OSM OpenStreetMap) without success. There no issue with the map file
map or layer definitions in terms of serving up the WMS in 27700 but
reprojection seems to fail. There appears to be very little online and I
cannot find a solution; hence this request for help or advice.

Relevant parts of map file (some parts removed):

PROJECTION
init=epsg:27700
END

WEB
METADATA
wms_title My WMS
wms_onlineresource  http://localhost/mapserver/mapserv.asp?;
wms_srs EPSG:27700  EPSG:900913
wms_enable_request *
wms_abstract My WMS 
wms_extent 0 0 67 123
wms_feature_info_mime_type text/plain
wms_feature_info_mime_type text/html
wms_feature_info_mime_type application/vnd.ogc.gml #
info_format=application/vnd.ogc.gml
...

Layer:

METADATA
wms_title CME
wms_extent 0 0 67 123
#wms_srs EPSG:27700 EPSG:900913
wms_include_items all # No spaces
gml_include_items all # No spaces
gml_featureid ID
END

PROJECTION
init=EPSG:27700
END # PROJECTION

Openlayers request:

http://maps1/cgi-bin/mapserv.exe?MAP=D:\MyMapFile.mapLAYERS=CMETRANSPARENT
=TRUEFORMAT=pngSERVICE=WMSVERSION=1.1.1REQUEST=GetMapSTYLES=SRS=EPSG%3
A900913BBOX=-484682.60504583,7512726.3043776,-415889.27960147,7547122.96709
97WIDTH=900HEIGHT=450

The result is a transparent image with no data showing. :( The same map file
works correctly and serves an image if used with Openlayers and a map on
EPSG 27700 so it's pointing at the reprojection of the BBOX maybe.

What am I doing wrong? Any help greatly appreciated.

Many thanks.

Regards,

Donald

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


Re: [mapserver-users] Mapserver WMS Reprojection

2013-05-19 Thread Donald Kerr
Slight mistake below; the projection definition in the layer is as follows
with epsg in lowercase as I am led to believe that it should be so:
init=epsg:27700

-Original Message-
From: mapserver-users-boun...@lists.osgeo.org
[mailto:mapserver-users-boun...@lists.osgeo.org] On Behalf Of Donald Kerr
Sent: 19 May 2013 20:36
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] Mapserver WMS Reprojection

Hi List,

I am trying to reproject a WMS request from 27700 (UK Ordnance Survey) to
900913 (OSM OpenStreetMap) without success. There no issue with the map file
map or layer definitions in terms of serving up the WMS in 27700 but
reprojection seems to fail. There appears to be very little online and I
cannot find a solution; hence this request for help or advice.

Relevant parts of map file (some parts removed):

PROJECTION
init=epsg:27700
END

WEB
METADATA
wms_title My WMS
wms_onlineresource  http://localhost/mapserver/mapserv.asp?;
wms_srs EPSG:27700  EPSG:900913
wms_enable_request *
wms_abstract My WMS 
wms_extent 0 0 67 123
wms_feature_info_mime_type text/plain
wms_feature_info_mime_type text/html
wms_feature_info_mime_type application/vnd.ogc.gml #
info_format=application/vnd.ogc.gml
...

Layer:

METADATA
wms_title CME
wms_extent 0 0 67 123
#wms_srs EPSG:27700 EPSG:900913
wms_include_items all # No spaces
gml_include_items all # No spaces
gml_featureid ID
END

PROJECTION
init=EPSG:27700
END # PROJECTION

Openlayers request:

http://maps1/cgi-bin/mapserv.exe?MAP=D:\MyMapFile.mapLAYERS=CMETRANSPARENT
=TRUEFORMAT=pngSERVICE=WMSVERSION=1.1.1REQUEST=GetMapSTYLES=SRS=EPSG%3
A900913BBOX=-484682.60504583,7512726.3043776,-415889.27960147,7547122.96709
97WIDTH=900HEIGHT=450

The result is a transparent image with no data showing. :( The same map file
works correctly and serves an image if used with Openlayers and a map on
EPSG 27700 so it's pointing at the reprojection of the BBOX maybe.

What am I doing wrong? Any help greatly appreciated.

Many thanks.

Regards,

Donald

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


-
No virus found in this message.
Checked by AVG - www.avg.com
Version: 2013.0.3336 / Virus Database: 3162/6338 - Release Date: 05/19/13

___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users