I am creating a game that uses multitouch, but only two fingers. I am
running into a problem where I get the up message for a pointer id
multiple times, which breaks my game. My code tracks the pointer ID
for any touches with an id less than 2, and it is running into a
problem where I get an up event for the same pointer ID back to back.
The problem seems to occur when more than two fingers are pressed.

Here is the log:
10-11 17:30:35.359 V/InputDevice( 2451): ID[2]=2(1) Dn(2=>3)
(This down is ignored because the ID is 2)
10-11 17:30:35.366 V/InputDevice( 2451): ID[0]=0(0) Up(3=>2)
10-11 17:30:35.370 I/Game(14165): Action POINTER up pointer id: 0
touch id: 55 pointer count 2
10-11 17:30:35.433 V/InputDevice( 2451): ID[0]=1(2) Up(2=>1)
10-11 17:30:35.441 I/Game(14165): Action POINTER up pointer id: 0
touch id: 0 pointer count 1

For my log messages, the touch ID is a non-repeating id I use instead
of the provided pointer id in my game code. The pointer count is the
number of pointers that I am tracking and are currently active before
the up event is processed.

In browsing through logs where my code worked, it seems like V/
InputDevice always said ID[0]=0(0) or ID[1]=1(1). It seems like the
problem only occurs when the InputDevice has numbers that don't
match.

My phone is a Sprint Epic 4G. Here's some more info if it matters.
 Device model: SPH-D700
 Firmware version: 2.2.1
 Kernel version: 2.6.32.9
k.sridhar@sep-33 )
#1 Sat Mar 5 17:01:33 KST 2011
 Build number: FROYO.EC05

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to