Use anchorXUnits and anchorYUnits in icon example

This commit is contained in:
Éric Lemoine
2014-01-07 17:41:24 +01:00
parent a0a94414dd
commit 09e5574350

View File

@@ -19,6 +19,9 @@ var raster = new ol.layer.Tile({
var styleArray = [new ol.style.Style({
image: new ol.style.Icon({
anchor: [0.5, 46],
anchorXUnits: 'fraction',
anchorYUnits: 'pixels',
src: 'data/icon.png'
})
})];