[OpenLayers-Users] WMS overlay onto google maps
Armin Wäspy
armin.waespy at lubw.bwl.de
Thu Oct 25 05:54:43 EDT 2007
Hi,
I'm trying to overlay some wms-layers (with arcims) onto google maps and it's not possible to add a new epsg to the ArcIms, so i can't work with epsg900913 like in http://trac.openlayers.org/wiki/SphericalMercator
is there any other possibility?
Is there a way to do this?
>>> Richard Duivenvoorde <rdmailings at duif.net> 10/25/07 11:44 >>>
Ok FIXED.... I can confirm myself now. Stuff lines up ok.
Old mistake: epsg:900913 was ok, but the string for the source
projection was wrong on the server (old dutch 28992 problem :-( )
Lining up beautifull now!
Richard D
Richard Duivenvoorde wrote:
> Hi List,
>
> I'm trying to overlay a google map with data from postgis database
> (roads). On larger scale things seem to be ok, but when zoomed in at
> 'meters' scale, roads do not match:
> http://www.duif.net/900913-mismatch.jpg
>
> Question: has somebody experienced this? Or does somebody have an
> example of perfect matching of two layers?
>
> When I look at the multimap mercator example:
> http://www.openlayers.org/dev/examples/multimap-mercator.html
> zooming in at for example Amsterdam, The Netherlands, I see about the
> same mismatch??
>
> my code:
>
> var options = {
> projection: "EPSG:900913",
> units: "m",
> maxResolution: 156543.0339,
> maxExtent: new OpenLayers.Bounds(-20037508, -20037508,
> 20037508, 20037508.34)
> };
> map = new OpenLayers.Map('map', options);
> var layer = new OpenLayers.Layer.Google( "Google Hybrid", {type:
> G_HYBRID_MAP, 'sphericalMercator': true});
> map.addLayer(layer);
>
> layer = new OpenLayers.Layer.WMS( "roads",
> 'http://localhost/cgi-bin/mapserv.exe?map=test.map&', {layers: 'roads',
> 'format':'image/gif', TRANSPARENT:true}, {'buffer': 0, isBaseLayer:
> false, singleTile: true} );
>
> Tried both reprojecting the data in postgis, using
> +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 +nadgrids=@null +no_defs
> OR
> let mapserver reproject the data. Both give about the same shifts...
>
> TIA
>
> Richard Duivenvoorde
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
>
_______________________________________________
Users mailing list
Users at openlayers.org
http://openlayers.org/mailman/listinfo/users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20071025/99c8d447/attachment.html
More information about the Users
mailing list