Allow interpolation to be configured for data tile sources

This commit is contained in:
Tim Schaub
2021-12-23 11:26:42 -07:00
parent 3edb5d6ddc
commit 8d8632bff7
14 changed files with 152 additions and 13 deletions
+7
View File
@@ -63,6 +63,8 @@ import {easeIn} from './easing.js';
* @typedef {Object} Options
* @property {number} [transition=250] A duration for tile opacity
* transitions in milliseconds. A duration of 0 disables the opacity transition.
* @property {boolean} [interpolate=false] Use interpolated values when resampling. By default,
* the nearest neighbor is used when resampling.
* @api
*/
@@ -123,6 +125,11 @@ class Tile extends EventTarget {
* @type {Object<string, number>}
*/
this.transitionStarts_ = {};
/**
* @type {boolean}
*/
this.interpolate = !!options.interpolate;
}
/**