# Unexpected POINTERTAP firing in touchscreen when zooming by two finger movement

**URL:** <https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922>\
**Category:** Bugs\
**Created:** [December 27, 2022, 5:33pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922 "2022-12-27T17:33:05Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![paoloz](https://avatars.discourse-cdn.com/v4/letter/p/f1d935/32.png) [@paoloz](https://forum.babylonjs.com/u/paoloz)\
**Post date:** [December 27, 2022, 5:33pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/1 "2022-12-27T17:33:05Z")

</div>

Hi friends,

in my project i’m using babylonjs 5.23.0, and i can’t upgrade engine to a more recent version because of an unexpected POINTERTAP event firing when zooming in touchscreen by a two finger movement.

Here a PG: [Babylon.js Playground](https://playground.babylonjs.com/#R5F7LR)  
I set an alert on POINTERTAP event for easy debug on mobile devices.  
Open it with a touchscreen device and try to zoom with a two finger movement.

This unexpected behavior is in latest engine (5.39.0) and newest previous, but not in 4.2.1 or in 5.23.0 i’m currently using in my project.

Many thanks for your help

---

<div class="post-metadata">

**Author:** ![Evgeni\_Popov](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/evgeni_popov/32/4432_2.png) [@Evgeni\_Popov](https://forum.babylonjs.com/u/Evgeni_Popov)\
**Post date:** [December 28, 2022, 10:59am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/2 "2022-12-28T10:59:50Z")

</div>

cc @PolygonalSun but be patient as it is vacation time.

---

<div class="post-metadata">

**Author:** ![sebavan](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/sebavan/32/57_2.png) [@sebavan](https://forum.babylonjs.com/u/sebavan)\
**Post date:** [January 2, 2023, 1:42pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/3 "2023-01-02T13:42:03Z")

</div>

Assigned @PolygonalSun on January 2, 2023, 1:42pm UTC



---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 5, 2023, 1:43am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/4 "2023-01-05T01:43:36Z")

</div>

I can take a look at this but it may be a couple of weeks because I’ll be out of the office. Just to confirm though, when you say “two finger movement”, are you talking about using a pinch or some other gesture?

---

<div class="post-metadata">

**Author:** ![paoloz](https://avatars.discourse-cdn.com/v4/letter/p/f1d935/32.png) [@paoloz](https://forum.babylonjs.com/u/paoloz)\
**Post date:** [January 5, 2023, 11:26am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/5 "2023-01-05T11:26:23Z")

</div>

Your vacations are definitely deserved!  
I thank you in advance so much for your interest.  
Unexpected POINTERTAP event is fired with ‘pinch’ movements (gestures for zoom in & out) but also with ‘two finger drag’ (gesture for pan).

---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 21, 2023, 12:24am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/6 "2023-01-21T00:24:42Z")

</div>

Just wanted to let you know that I’m back and will be looking at this to see what’s going on.

---

<div class="post-metadata">

**Author:** ![paoloz](https://avatars.discourse-cdn.com/v4/letter/p/f1d935/32.png) [@paoloz](https://forum.babylonjs.com/u/paoloz)\
**Post date:** [January 23, 2023, 4:48pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/7 "2023-01-23T16:48:21Z")

</div>

I would like to specify that unexpected POINTERTAP event is fired **at the end/after** a two finger movement on a touchscreen device, like zooming or panning.  
Do you agree that such an event is unwanted?  
Thanks for your help.

---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 24, 2023, 11:53pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/8 "2023-01-24T23:53:39Z")

</div>

Just an update, so it looks like the issue is that the InputManager’s logic for determining a TAP isn’t accounting for multiple active touches. I’m currently testing a fix for this. I’ll provide an update once this is in PR.

---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 25, 2023, 9:07pm UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/9 "2023-01-25T21:07:13Z")

</div>

PR is live: [InputManager: Fix for POINTERTAP firing during multi-touch gesture by PolygonalSun · Pull Request #13466 · BabylonJS/Babylon.js (github.com)](https://github.com/BabylonJS/Babylon.js/pull/13466)

---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 26, 2023, 12:04am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/10 "2023-01-26T00:04:48Z")

</div>

PR is merged

---

<div class="post-metadata">

**Author:** ![PolygonalSun](https://sea2.discourse-cdn.com/flex024/user_avatar/forum.babylonjs.com/polygonalsun/32/2704_2.png) [@PolygonalSun](https://forum.babylonjs.com/u/PolygonalSun)\
**Post date:** [January 26, 2023, 12:04am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/11 "2023-01-26T00:04:50Z")

</div>

Unassigned @PolygonalSun on January 26, 2023, 12:04am UTC



---

<div class="post-metadata">

**Author:** ![paoloz](https://avatars.discourse-cdn.com/v4/letter/p/f1d935/32.png) [@paoloz](https://forum.babylonjs.com/u/paoloz)\
**Post date:** [January 26, 2023, 10:57am UTC](https://forum.babylonjs.com/t/unexpected-pointertap-firing-in-touchscreen-when-zooming-by-two-finger-movement/36922/12 "2023-01-26T10:57:31Z")

</div>

What a fantastic support team! I thank you infinitely.
