diff --git a/packages/display/src/displays/webgl/buffer/FeatureFactory.ts b/packages/display/src/displays/webgl/buffer/FeatureFactory.ts index 08796f40a..fb4876e8b 100644 --- a/packages/display/src/displays/webgl/buffer/FeatureFactory.ts +++ b/packages/display/src/displays/webgl/buffer/FeatureFactory.ts @@ -57,7 +57,7 @@ import {GradientFactory} from '../GradientFactory'; import {HeatmapBuffer} from './templates/HeatmapBuffer'; import {TextureAtlasManager} from '../TextureAtlasManager'; import {LineBuffer} from './templates/LineBuffer'; -import {Color as ColorUtils, Expression} from '@here/xyz-maps-common'; +import {Color as ColorUtils, Expression, ExpressionMode} from '@here/xyz-maps-common'; const {toRGB} = ColorUtils; type RGBA = ColorUtils.RGBA; @@ -136,7 +136,7 @@ export type GroupMap = { [zIndex: string]: ZDrawGroup }; export const isDynamicProperty = (prop: any) => prop instanceof Expression; // const isDynamicProperty = (prop: any) => typeof prop == 'function'; -const DYNAMIC_MODE = 1; +const DYNAMIC_MODE = ExpressionMode.dynamic; const PIXEL_UNITS = ['px', 'px']; export class FeatureFactory { diff --git a/packages/display/src/displays/webgl/buffer/createBuffer.ts b/packages/display/src/displays/webgl/buffer/createBuffer.ts index e47df238f..9d65ae833 100644 --- a/packages/display/src/displays/webgl/buffer/createBuffer.ts +++ b/packages/display/src/displays/webgl/buffer/createBuffer.ts @@ -214,14 +214,10 @@ const createBuffer = ( if (shared.strokeDasharray) { geoBuffer.type = 'DashedLine'; - // if (isDynamicProperty(shared.strokeDasharray)) { - // geoBuffer.addUniform('u_dashUnit', [0, 0]); - // } else { geoBuffer.addUniform('u_dashUnit', [ shared.strokeDasharray.units[0] == 'm' ? meterToPixel : 0, shared.strokeDasharray.units[1] == 'm' ? meterToPixel : 0 ]); - // } } // scissor un-clipped geometry in any case...(huge geometry possible) // otherwise clipping can be skipped to avoid strokeWidth cutoffs close to tile edges