[OpenLayers-Users] WMS layer overlay on google map

Subha Ramakrishnan subha at gslab.com
Wed Feb 4 08:01:04 EST 2009


Thanks for the reply.

My map file did have the same configuration as mentioned in the link.
The problem is that the data shows up only when i give a particular 
extent (1610000,6568500,1638000,6594000 in meters) as bbox parameter.
So, when i show the entire world on my OL base map, and send a request 
to fetch this WMS layer, the bbox sent in the request is different and 
so i get only a blank image.
I also tried setting the maxExtent in the WMS parameters as this value 
but doesn't help.

The extent corresponds to Stockholm.

Please help.
Thanks a lot.

Subha

Jan van der Ven wrote:
> Subha Ramakrishnan wrote:
>> Hi,
>>
>> I want to overlay a WMS layer on google base map (Google Physical).
>> The image that I have is a raster data and am using MapServer to show 
>> the image.
>> The data is in Transverse Mercator projection.
>>
>> I'm able to get the image when I hit the mapserver url in the 
>> browser, provided i give the extent in meters for that particular 
>> country but using OL, i get only a blank image.
>> The projection is 4326 in the map file.
>>
>> OL code:
>> var twms1 = new OpenLayers.Layer.WMS( 
>> "Land_use_cover_from_SPOT","http://localhost/cgi-bin/mapserv?",
>>             { map: "Land_use_cover_from_SPOT.map",
>>             units: "m",
>>               transparent: 'true', layers:"Land_use_cover_from_SPOT",
>>               format: 'image/png',
>>             maxExtent: new 
>> OpenLayers.Bounds(1610000,6568500,1638000,6594000),
>>               //maxExtent: new OpenLayers.Bounds(60,0,100,40)
>>               //maxResolution: 156543.0339,
>>               projection:"EPSG:4326",reproject:false
>>                          },{singleTile: 'true'});
>> map.addLayers([twms1]);
>>
>> Does some one know how to project transverse mercator on Google map??
>>
>> Please help.
>>
>> Thanks & regards,
>> Subha
>> _______________________________________________
>> Users mailing list
>> Users at openlayers.org
>> http://openlayers.org/mailman/listinfo/users
>>
>>
>>   
> http://docs.openlayers.org/library/spherical_mercator
>
>




More information about the Users mailing list