Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: PixelEnvision on June 29, 2012, 08:29:00 PM
-
Hi,
I'm curious if there are any multitouch enhancements on your roadmap.... I've few issues and it seems like that's how NGUI currently works.
When "allow multi touch" is enabled on camera settings, camera appears to be sending two (or more) different touch events for each finger. When using it with drag scripts (Panels, etc) it's jumping between two fingers... That can be easily seen at the example 6. Just run it on the device (I'm using Kindle Fire btw, didn't tested that on iOS yet) and touch the green drag area with two fingers.
If I disable multitouch on camera, then it only looks for fist finger. As data is coming from a single finger, jumping problem is gone but the problem is, if there is a touch somewhere else and widgets accessed by 2nd finger, it's ignored...
I've also tried sending finger gestures delta to UIDraggablePanel but it's public Drag function is not actually using the delta value even if it appears to take it in... I've managed to move the panel with it but couldn't get momentum & spring...
Any info appreciated! :)
-
Ideally you should "save" the ID of the touch that started the drag (in OnPress(true)), and check it in OnDrag. If it doesn't match, ignore it. I'll make note of it.
-
Ideally you should "save" the ID of the touch that started the drag (in OnPress(true)), and check it in OnDrag. If it doesn't match, ignore it. I'll make note of it.
Thanks for the reply...
I thought of that but Camera doesn't sends touch id (or it does?) to drag components. Or are you suggesting using a global touch checker to get the touch id? In with case how can match touch id with finger?
Edit: I should RTFM first, I think UICamera.currentTouchID will provide what I need...
-
Yup, UICamera.currentTouchID :)