[mapserver-users] Maxextent , resolution and zoom issue
jbloc1878 at googlemail.com
jbloc1878 at googlemail.com
Tue Feb 2 12:04:09 PST 2010
Hi, i have been struggling with this problem for some time now.
Basically I am trying to display two layers. 50k and 250K of the uk.
Can anyone explain further what resolution, maxextent and zoom values
I should have to display these layers correctly? My layers cover the
whole of the UK. I have tried quite a few different values however I
cannot make sense of how this works. The example I am referring to is
below.
Thanks for any help in advance
Create an options object that holds a limited set of map resolutions
and a maximum bounding extent to show the map. A new OS OpenSpace map
object is created by passing in our 'map' HTML div element id and the
map options.
1. var options = {resolutions: [10, 5],
2. maxExtent: new OpenSpace.MapBounds(400000,
100000, 450000, 150000) );
3. osMap = new OpenSpace.Map('map', options);
We now set the centre of the map and set the initial map zoom level to
1 (corresponding to the second defined layer in the resolutions array).
1. osMap osMap.setCenter(new OpenSpace.MapPoint(400000,100000), 1);
Cheers
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20100202/4e960062/attachment.htm>
More information about the MapServer-users
mailing list