Hi all,<br>
<br>
I would like to have a custom layer (different from the baselayer) and
a custom projection (same as the base layer of course) in my
overviewmap:<br>
<br>
I've tried this:<br>
<br>
//baselayer based on tilecache<br>baseLayer = new OpenLayers.Layer.WMS ( "Carte de base",<br>
["<a href="http://osl1/tilecache/tilecache.py">http://osl1/tilecache/tilecache.py</a>?",<br>
"<a href="http://osl2/tilecache/tilecache.py">http://osl2/tilecache/tilecache.py</a>?",<br>
"<a href="http://osl3/tilecache/tilecache.py">http://osl3/tilecache/tilecache.py</a>?",<br>
"<a href="http://osl4/tilecache/tilecache.py">http://osl4/tilecache/tilecache.py</a>?"<br>
],<br>
{ layers : "siglight3",<br>
map_projection: "init=epsg:42105",<br>
transparent: "true" },<br>
{ isBaseLayer: true }<br>
);<br>
<br>
//WMS layer for the overview<br>
var wms_ov = new OpenLayers.Layer.WMS ( "overview",<br>
"http:/...",<br>
{ layers : "muncp",<br>
map_projection: "init=epsg:42105",<br>
transparent: "true",<br>
format: "gif"<br>
},<br>
{ isBaseLayer: false, singleTile: true }<br>
);<br>
//options for the ov (from the ol wiki)<br>
var ov_options = {layers: [wms_ov],<br>
maxExtent: new OpenLayers.Bounds(30000, 75000, 1709360, 2120440),<br>
projection:"EPSG:42105",<br>
units: "m"<br>
};<br>
<br>
//adding the control<br>
var overview = new OpenLayers.Control.OverviewMap( {mapOptions: ov_options} );<br>
map.addControl(overview); <br>
<br>
With this configuration, I still have a popup message you tell me that
the projection of the ov must be equal to the one in the baselayer
(Why?). <br>
And, If a check the call made by openlayers for the ov, the SRS seem to
be 4326 (why?) and the bounding box is in lat/lon (Why?).<br>
<br><a href="http://mdrim00-000251/MapServer5/mapserv.exe?MAP=overview.map&LAYERS=direction_territoriale&MAP_PROJECTION=init%3Depsg%3A42105&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&FORMAT=image%2Fjpeg&SRS=EPSG%3A4326&BBOX=-180,-90,332,422&WIDTH=256&HEIGHT=256">http://mdrim00-000251/MapServer5/mapserv.exe?MAP=overview.map&LAYERS=direction_territoriale&MAP_PROJECTION=init%3Depsg%3A42105&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&EXCEPTIONS=application%2Fvnd.ogc.se_inimage&FORMAT=image%2Fjpeg&SRS=EPSG%3A4326&BBOX=-180,-90,332,422&WIDTH=256&HEIGHT=256</a><br>
any advice on this?<br>
<br>
MartinO