[OpenLayers-Users] OverviewMap problem

lukast lukast at poczta.fm
Tue Jul 22 06:55:34 EDT 2008


Dear All,

I have problem with OverviewMap control.
I am using OL 2.6. The problem is that my main map works fine, but
overviewMap control not - I have 11 zoom levels and overviewMap control
shows map at the same scale as main map at first 3 zoom levels. I would like
it to show the map at smaller scale so that it would show bigger area and
only red square on it would mark current map extends. I have also tried to
comment or change overvieMap "maxResolution" parameter. When it is commented
(not included in options) overviewMap's scale is ok, but its projection not
and red quare shows different area than current map extends.
Thans in advance for your helpfull remarks.

Here is my code:

var map = new OpenLayers.Map('map',
	{
	 alpha: false,
	 maxExtent: new OpenLayers.Bounds(-100000, -150000, 1100000, 1050000),
	 restrictedExtent: new OpenLayers.Bounds(-100000, -150000, 1100000,
1050000),
	 maxResolution: 1000000/1280,
	 units: 'meters',
	 projection: "EPSG:2180",
	 tileSize: new OpenLayers.Size(256,256),
	 numZoomLevels: 11,
	 controls: [createZoomBarControl(),new OpenLayers.Control.MouseToolbar()]
	 
	 
	 });

var options = {
       maxExtent: new OpenLayers.Bounds(-100000, -150000, 1100000, 1050000),
	   restrictedExtent: new OpenLayers.Bounds(-100000, -150000, 1100000,
1050000),
	   maxResolution: 1000000/1280,
	   units: 'meters',
	   projection: "EPSG:2180",
	   tileSize: new OpenLayers.Size(256,256),
	   numZoomLevels: 11
    };

var overviewMap = new OpenLayers.Control.OverviewMap({mapOptions: options});
	
	
 map.addControl(overviewMap);
-- 
View this message in context: http://www.nabble.com/OverviewMap-problem-tp18586877p18586877.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.




More information about the Users mailing list