I am creating an OverviewMap control in the map and want to see the content of a Vector layer in the overview map too.
var mapOverviewOptions = {
mapOptions: {
projection: new OpenLayers.Projection("EPSG:900913"),
displayProjection: new OpenLayers.Projection("EPSG:4326"),
},
layers: [baseOverviewLayer, myVectorLayer]
};
var ovMap = new OpenLayers.Control.OverviewMap(mapOverviewOptions);
This does not work. It only displays the world map background and does not display the vector data that gets rendered on the map.
Is it possible to display the vector layer data in the overview map?
I tried adding the vector layer to the map object that Overview Control creates,
ovMap.ovmap.addLayer(myVectorLayer)
but that does not help either.