Processing & multitouch

I wasn’t supposed to be doing this today, but:

Multitouch support on Linux seems much simpler with a different library than SMT that I was unsuccessfully tryin last year. “Simple Touch” actually “just works” via evdev library. The only thing that was needed was to supply the right event device from /dev/input and also make it readable and writable for normal user.

Find out which event device is your touch screen:

Above you see that id of the touch-screen is 11. Which means we have to allow access to /dev/input/event11.

Alternatively (and perhaps much more reliably) one should check the contents of /dev/input/by-id/

You can see that the touch-screen reports to be device “../event5”.

Simple Touch library is available from the Tools menu in Processing, but also here:

In Processing there is couple of examples for Simple Touch library, but the essence for a successful start is

1) list devices

will output something like

Touch-screen (event11) has [3] index, so to open this device you finally use

It seems also to be possible to do just this:

and the following also works:

This opens the door for writing multitouch interfaces in Processing, which however means a lot more work. For now it seems a good way to go with writing control GUI in SuperCollider, but eventually, the Processing possibility seems like very interesting and inviting.

So a final complete working example for my machine is this: