Last change
on this file since 8990 was 8990, checked in by dennisw, 14 years ago |
gheat - 2 overlays toegevoegd (afbeeldingen)
|
-
Property svn:eol-style
set to
native
-
Property svn:keywords
set to
Date Revision
-
Property svn:mime-type
set to
text/plain
|
File size:
1.1 KB
|
Rev | Line | |
---|
[8987] | 1 | function init(){
|
---|
[8988] | 2 | map = new OpenLayers.Map('heatmap', {
|
---|
| 3 | controls: [
|
---|
| 4 | new OpenLayers.Control.Navigation(),
|
---|
| 5 | new OpenLayers.Control.PanZoomBar(),
|
---|
| 6 | new OpenLayers.Control.ScaleLine(),
|
---|
| 7 | new OpenLayers.Control.LayerSwitcher()
|
---|
| 8 | ],
|
---|
| 9 | maxExtent: new OpenLayers.Bounds(-20037508.3427892,-20037508.3427892,20037508.3427892,20037508.3427892),
|
---|
| 10 | numZoomLevels:18,
|
---|
| 11 | maxResolution:156543.0339,
|
---|
| 12 | units:'m',
|
---|
| 13 | projection: "EPSG:900913",
|
---|
| 14 | displayProjection: new OpenLayers.Projection("EPSG:4326")
|
---|
| 15 | });
|
---|
| 16 |
|
---|
[8987] | 17 | layerMapnik = new OpenLayers.Layer.OSM.Mapnik("Mapnik");
|
---|
| 18 | map.addLayer(layerMapnik);
|
---|
[8990] | 19 | layerHeatmap = new OpenLayers.Layer.OSM.Overlay1("Overlay_1", {isBaseLayer: false, visibility: true});
|
---|
[8988] | 20 | map.addLayer(layerHeatmap);
|
---|
[8990] | 21 | layerHeatmap = new OpenLayers.Layer.OSM.Overlay2("Overlay_2", {isBaseLayer: false, visibility: true});
|
---|
| 22 | map.addLayer(layerHeatmap);
|
---|
[8988] | 23 |
|
---|
[8987] | 24 | var lon = 4.4585017;
|
---|
| 25 | var lat = 52.1406583;
|
---|
| 26 | var zoom = 13;
|
---|
| 27 |
|
---|
| 28 | var lonLat = new OpenLayers.LonLat(lon, lat).transform(new OpenLayers.Projection("EPSG:4326"), map.getProjectionObject());
|
---|
| 29 | map.setCenter (lonLat, zoom);
|
---|
| 30 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.