Alexandre Dubé 7426267e25 Fix \#4 - Deal with rotation
This patch introduces documentation about the limitations of this
library, notably the 'rotation' that should not be enabled, as
mentioned in \#4.

A new `LIMITATIONS.md` file was added to document this.

A new utility method that returns the default interactions that
include  only the ones that are recommended
(well, more like 'exclude' those that aren't).
2015-10-07 14:28:05 -04:00

21 lines
485 B
JavaScript

var center = [-7908084, 6177492];
// This dummy layer tells Google Maps to switch to its default map type
var googleLayer = new olgm.layer.Google();
var map = new ol.Map({
// use OL3-Google-Maps recommended default interactions
interactions: olgm.interaction.defaults(),
layers: [
googleLayer
],
target: 'map',
view: new ol.View({
center: center,
zoom: 12
})
});
var olGM = new olgm.OLGoogleMaps({map: map}); // map is the ol.Map instance
olGM.activate();