Has anyone had any trouble implementing multitouch on-screen controls in libGDX, such as multiple joysticks? I've tried and I can't seem to get libGDX to play nice with multitouch/multiple pointers on screen at once. I am currently using a Stage with my joystick class extending Actor and they are detecting hits just fine, but when I touch one it interferes with the other. Any examples, or tips? I should note, that when I am using just one of the joysticks that they work as intended.

  • \$\begingroup\$ libgdx is supposed to support multitouch. How are you registering touch events? \$\endgroup\$ Mar 12 '12 at 12:52
  • \$\begingroup\$ The touch events are registered via Gdx.input.setInputProcessor(stage); I am getting touch input all the way through to the correct Actor although as soon as I get a second finger on the screen it causes a touchUp() on the first finger. Do you think maybe it is a device problem? I have a Galaxy Nexus. Maybe I'll try testing on another device... \$\endgroup\$ Mar 12 '12 at 13:30
  • 2
    \$\begingroup\$ There seems to be issues with the Galaxy Nexus touchscreen, see here code.google.com/p/android/issues/… \$\endgroup\$
    – DRiFTy
    Mar 12 '12 at 13:47
  • \$\begingroup\$ Glad to hear that I'm not the only one with this problem. It looks like it is definitely a device problem. I can reproduce the problem exactly how it is explained in the link above. Thanks for pointing that out. \$\endgroup\$ Mar 12 '12 at 13:54
  • \$\begingroup\$ @Alex_Hyzer_Kenoyer, curiosly, do you involve also with the drag-n-drop using touchDrag() under implementing input processor or you just focus only on multi-touch command? And, are using Eclipse for Java IDE developers when you're making Android game apps? \$\endgroup\$ Dec 6 '12 at 6:45

Turns out this was a device independent problem (See comments above) and the issue posted to Google Code can be found here. There was actually no problem with the code in libGDX. I'm Posting this as an answer rather than deleting so that people like me can find the answer before ripping their hair out.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .