[mapserver-users] Openlayers + Bing Maps with Mapserver WMS projection error...

2010-08-11 Thread Paul james
Hey guys...
When using Bing maps as base layer, I have huge difference between my data
... Both are using WGS84 projection...
The image is attached...

Any idea?

Thanks

My WMS map:
MAP
...
  PROJECTION
+init=epsg:4326
  END

 WEB
IMAGEPATH 'D:\Temp'
IMAGEURL '/tmp/'
QUERYFORMAT 'text/html'

METADATA
wms_title WMS Server  ##required
wms_onlineresource http://localhost/cgi-bin/mapserv.exe?;
##required
wms_srs   EPSG:4269 EPSG:4326 EPSG:42304 EPSG:42101
EPSG:900913  ##recommended
wms_feature_info_mime_type text/html
labelcache_map_edge_buffer
  -10
END
END
...

LAYER
NAME STATE
METADATA
wms_titleSTATE   ##required
wms_feature_info_mime_type text/html
END

TYPE polygon
STATUS ON
INCLUDE Connection.map
DATA ...
PROCESSING CLOSE_CONNECTION=DEFER
PROCESSING LABEL_NO_CLIP=ON

PROJECTION
init=epsg:4326
END
...


My Openlayers config:

 map = new OpenLayers.Map('Test', {
 resolutions: [0.09524345064126273, 0.0730199788249681,
0.047621725320631365, 0.031747816880420915, 0.015873908440210457,
0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457,
0.0007936954220105228, 0.00031747816880420915],
projection: EPSG:4326,
displayProjection: new OpenLayers.Projection(EPSG:4326),
tileSize: new OpenLayers.Size(400, 400),
maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125,
4.7021484375, 13.623046875)
});
attachment: bing4.gif___
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users


RE: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS projection error...

2010-08-11 Thread Edward Mac Gillavry

Bing maps is also using EPSG: 900913, EPSG:3785 or EPSG:3857 whichever is the 
latest... That should do the trick.

HTH

Edward



Date: Wed, 11 Aug 2010 11:12:47 -0300
From: paulj...@gmail.com
To: mapserver-users@lists.osgeo.org
Subject: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS
projection error...

Hey guys...
When using Bing maps as base layer, I have huge difference between my data ... 
Both are using WGS84 projection...
The image is attached...

Any idea?

Thanks

My WMS map:
MAP
...


  PROJECTION
+init=epsg:4326
  END

 WEB   
IMAGEPATH 'D:\Temp'
IMAGEURL '/tmp/'
QUERYFORMAT 'text/html'

METADATA   


wms_title WMS Server  ##required
wms_onlineresource http://localhost/cgi-bin/mapserv.exe?;   
##required


wms_srs   EPSG:4269 EPSG:4326 EPSG:42304 EPSG:42101 
EPSG:900913  ##recommended
wms_feature_info_mime_type text/html 
labelcache_map_edge_buffer  
  -10

END
END
...

LAYER
NAME STATE
METADATA
wms_titleSTATE   ##required
wms_feature_info_mime_type text/html 


END

TYPE polygon
STATUS ON
INCLUDE Connection.map 
DATA ...
PROCESSING CLOSE_CONNECTION=DEFER


PROCESSING LABEL_NO_CLIP=ON

PROJECTION
init=epsg:4326
END
...


My Openlayers config:

 map = new OpenLayers.Map('Test', {


 resolutions: [0.09524345064126273, 0.0730199788249681, 
0.047621725320631365, 0.031747816880420915, 0.015873908440210457, 
0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457, 
0.0007936954220105228, 0.00031747816880420915],  

projection: EPSG:4326,
displayProjection: new OpenLayers.Projection(EPSG:4326),
tileSize: new OpenLayers.Size(400, 400),  
maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125, 
4.7021484375, 13.623046875)


});

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


Re: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS projection error...

2010-08-11 Thread Paul james
Thanks for the help...
I tried use spherical marcator like that:

 var bing= new OpenLayers.Layer.VirtualEarth(Shaded, {
   type: VEMapStyle.Shaded, numZoomLevels: 10,sphericalMercator: true
  });

And use that projection in mapfile and openlayers:
PROJECTION
+init=epsg:3857

Openlayers
 map = new OpenLayers.Map('Test', {
 resolutions: [0.09524345064126273, 0.0730199788249681,
0.047621725320631365, 0.031747816880420915, 0.015873908440210457,
0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457,
0.0007936954220105228, 0.00031747816880420915],
projection: EPSG:4326,
maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125,
4.7021484375, 13.623046875)
});


But using that, my wms layers disappear... To other projection maybe?

Any idea?

Thanks


On Wed, Aug 11, 2010 at 12:35 PM, Edward Mac Gillavry 
emacgilla...@hotmail.com wrote:

  Bing maps is also using EPSG: 900913, EPSG:3785 or EPSG:3857 whichever is
 the latest... That should do the trick.

 HTH

 Edward



 --
 Date: Wed, 11 Aug 2010 11:12:47 -0300
 From: paulj...@gmail.com
 To: mapserver-users@lists.osgeo.org
 Subject: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS
 projection error...


 Hey guys...
 When using Bing maps as base layer, I have huge difference between my data
 ... Both are using WGS84 projection...
 The image is attached...

 Any idea?

 Thanks

 My WMS map:
 MAP
 ...
   PROJECTION
 +init=epsg:4326
   END

  WEB
 IMAGEPATH 'D:\Temp'
 IMAGEURL '/tmp/'
 QUERYFORMAT 'text/html'

 METADATA
 wms_title WMS Server  ##required
 wms_onlineresource http://localhost/cgi-bin/mapserv.exe?;
 ##required
 wms_srs   EPSG:4269 EPSG:4326 EPSG:42304 EPSG:42101
 EPSG:900913  ##recommended
 wms_feature_info_mime_type text/html
 labelcache_map_edge_buffer
   -10
 END
 END
 ...

 LAYER
 NAME STATE
 METADATA
 wms_titleSTATE   ##required
 wms_feature_info_mime_type text/html
 END

 TYPE polygon
 STATUS ON
 INCLUDE Connection.map
 DATA ...
 PROCESSING CLOSE_CONNECTION=DEFER
 PROCESSING LABEL_NO_CLIP=ON

 PROJECTION
 init=epsg:4326
 END
 ...


 My Openlayers config:

  map = new OpenLayers.Map('Test', {
  resolutions: [0.09524345064126273, 0.0730199788249681,
 0.047621725320631365, 0.031747816880420915, 0.015873908440210457,
 0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457,
 0.0007936954220105228, 0.00031747816880420915],
 projection: EPSG:4326,
 displayProjection: new OpenLayers.Projection(EPSG:4326),
 tileSize: new OpenLayers.Size(400, 400),
 maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125,
 4.7021484375, 13.623046875)
 });

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

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


Re: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS projection error...

2010-08-11 Thread Luigi Castro Cardeles
Hi,

try http://trac.openlayers.org/wiki/SphericalMercator

...

This can be added to /usr/share/epsg/proj, and thus
MapServerhttp://trac.openlayers.org/wiki/MapServer,
GDAL, etc. by adding the following line to the file:

900913 +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0
+x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgri...@null +no_defs

...

[]'s
Luigi Castro Cardeles


2010/8/11 Paul james paulj...@gmail.com

 Thanks for the help...
 I tried use spherical marcator like that:

  var bing= new OpenLayers.Layer.VirtualEarth(Shaded, {
type: VEMapStyle.Shaded, numZoomLevels: 10,sphericalMercator: true
   });

 And use that projection in mapfile and openlayers:
 PROJECTION
 +init=epsg:3857

 Openlayers

  map = new OpenLayers.Map('Test', {
  resolutions: [0.09524345064126273, 0.0730199788249681,
 0.047621725320631365, 0.031747816880420915, 0.015873908440210457,
 0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457,
 0.0007936954220105228, 0.00031747816880420915],
 projection: EPSG:4326,
 maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125,
 4.7021484375, 13.623046875)
 });


 But using that, my wms layers disappear... To other projection maybe?

 Any idea?

 Thanks


 On Wed, Aug 11, 2010 at 12:35 PM, Edward Mac Gillavry 
 emacgilla...@hotmail.com wrote:

  Bing maps is also using EPSG: 900913, EPSG:3785 or EPSG:3857 whichever is
 the latest... That should do the trick.

 HTH

 Edward



 --
 Date: Wed, 11 Aug 2010 11:12:47 -0300
 From: paulj...@gmail.com
 To: mapserver-users@lists.osgeo.org
 Subject: [mapserver-users] Openlayers + Bing Maps with Mapserver WMS
 projection error...


 Hey guys...
 When using Bing maps as base layer, I have huge difference between my data
 ... Both are using WGS84 projection...
 The image is attached...

 Any idea?

 Thanks

 My WMS map:
 MAP
 ...
   PROJECTION
 +init=epsg:4326
   END

  WEB
 IMAGEPATH 'D:\Temp'
 IMAGEURL '/tmp/'
 QUERYFORMAT 'text/html'

 METADATA
 wms_title WMS Server  ##required
 wms_onlineresource http://localhost/cgi-bin/mapserv.exe?;
 ##required
 wms_srs   EPSG:4269 EPSG:4326 EPSG:42304 EPSG:42101
 EPSG:900913  ##recommended
 wms_feature_info_mime_type text/html
 labelcache_map_edge_buffer
   -10
 END
 END
 ...

 LAYER
 NAME STATE
 METADATA
 wms_titleSTATE   ##required
 wms_feature_info_mime_type text/html
 END

 TYPE polygon
 STATUS ON
 INCLUDE Connection.map
 DATA ...
 PROCESSING CLOSE_CONNECTION=DEFER
 PROCESSING LABEL_NO_CLIP=ON

 PROJECTION
 init=epsg:4326
 END
 ...


 My Openlayers config:

  map = new OpenLayers.Map('Test', {
  resolutions: [0.09524345064126273, 0.0730199788249681,
 0.047621725320631365, 0.031747816880420915, 0.015873908440210457,
 0.009524345064126272, 0.0031747816880420914, 0.0015873908440210457,
 0.0007936954220105228, 0.00031747816880420915],
 projection: EPSG:4326,
 displayProjection: new OpenLayers.Projection(EPSG:4326),
 tileSize: new OpenLayers.Size(400, 400),
 maxExtent: new OpenLayers.Bounds(-102.2607421875, -46.142578125,
 4.7021484375, 13.623046875)
 });

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



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


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