Icon webgl example / avoid doing hit detection when view is moving

This commit is contained in:
Olivier Guyot
2019-10-31 14:19:39 +01:00
parent 600e1a4647
commit af15cfb815

View File

@@ -59,7 +59,7 @@ const style = {
rotateWithView: false,
offset: [
0,
9
0
],
textureCoord: [
'match',
@@ -144,7 +144,7 @@ map.addLayer(
const info = document.getElementById('info');
map.on('pointermove', function(evt) {
if (map.getView().getInteracting()) {
if (map.getView().getInteracting() || map.getView().getAnimating()) {
return;
}
const pixel = evt.pixel;