Wish: Multi-Touch

Jim Brown

Active Member
Licensed User
Longtime User
Multi-touch would be a nice feature to have. My Galaxy S can handle up to 5 touch points at a time but I assume this varies from device to device

Probably the best implementation then would be via arrays. The array size would indicate the amount of points received
B4X:
Sub Activity_MultiTouch(Action As Int , X() As Float, Y() As Float)
End Sub
 

agraham

Expert
Licensed User
Longtime User
I'm looking at it but it will have to be a bit more complicated than just using arrays as you need to know not only how many simultaneous touches there are but which are new ones and which relate to previous ones so you need some means to identify and track each individual touch.

There's other stuff to look at as well, especially historic positions for each point of contact because multi-touch can generate more data than can be handled by individual events so Android buffers rapid movement changes to provide a fine-grained capture of movement data without overloading the processor with many event calls.

The trick with implementing multi-touch will be in providing a simplified model of Android's quite complicated multi-touch handling that is nonetheless useful in Basic4android.
 
Top