diff --git a/src/ol/style/imagestyle.js b/src/ol/style/imagestyle.js new file mode 100644 index 0000000000..867b4e9f20 --- /dev/null +++ b/src/ol/style/imagestyle.js @@ -0,0 +1,49 @@ +// FIXME export ol.style.Image +// FIXME decide default value for snapToPixel + +goog.provide('ol.style.Image'); + + +/** + * @typedef {{anchor: Array., + * image: (HTMLCanvasElement|HTMLVideoElement|Image), + * rotation: number, + * snapToPixel: (boolean|undefined), + * subtractViewRotation: boolean}} + */ +ol.style.ImageOptions; + + + +/** + * @constructor + * @param {ol.style.ImageOptions} options Options. + */ +ol.style.Image = function(options) { + + /** + * @type {Array.} + */ + this.anchor = options.anchor; + + /** + * @type {HTMLCanvasElement|HTMLVideoElement|Image} + */ + this.image = options.image; + + /** + * @type {number} + */ + this.rotation = options.rotation; + + /** + * @type {boolean|undefined} + */ + this.snapToPixel = options.snapToPixel; + + /** + * @type {boolean} + */ + this.subtractViewRotation = options.subtractViewRotation; + +};