0
votes

I follow these steps to download Multi-Touch Vista and configure it to simulate finger touch using multiple mice.

It works well, now I have two red dots on screen, each controlled by a mouse.

And I then write a WPF application, which has a single window with a Canvas, and in the Canvas's TouchDown event handler, I log which finger (mouse) is touching the screen.

private void canvas_TouchDown(object sender, TouchEventArgs e)
{
    System.Diagnostics.Debug.WriteLine(e.TouchDevice.Id);
} 

But to my surprise, the Id is always 258, no matter which mouse I use - I expect it to be starting from 0 or 1, and the Id is different between 2 fingers (mice).

I am testing on Win7 32bit.

1

1 Answers

0
votes

I bought a touch monitor recently and I can test the same code on the new monitor. It turns out the Id property is only useful when multiple touches (fingers/stylus) are present, the first touch device will get assigned a "base Id", the second touch device will be assigned ("base Id "+ 1), and so on. On my new touch monitor, when I use all my ten fingers, they will be assigned Ids as 428, 429, 430,..., 437.

I guess the "base Id" can vary on different monitors.