Hi,
 
that's from an OS OpenSpace map for the whole UK:
 
osMap.getMaxResolution() : 2500
osMap.getExtent() for zoomLevel 0 (whole UK) : left-bottom=(-611483,-135514)
right-top=(1888517,1364486) 
osMap.resolutions : [2500,1000,500,200,100,50,25,10,5,2,1]
 
The example you refer to, seems to display only a small area of the UK,
perhaps Southampton.
 
Arnd

  _____  

Von: [email protected] [mailto:[email protected]] Im
Auftrag von [email protected]
Gesendet: Dienstag, 2. Februar 2010 18:52
An: [email protected]
Betreff: [OpenLayers-Users] Maxextent, resolution and zoom issue


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



_______________________________________________
Users mailing list
[email protected]
http://openlayers.org/mailman/listinfo/users

Reply via email to