WorldViz User Forum

WorldViz User Forum (
-   Vizard (
-   -   Touch functionality (

Joran 04-18-2012 01:31 AM

Touch functionality

I have been working with the touch functionality and have played with viztouch. I haven't installed the latest version of Vizard yet, so I am at risk this has already been solved, but I will go for it anyway.

If you use Vizard on Windows 7 with a touch screen there is mouse emulation. The problem with mouse emulation is that when you touch the screen, no mouse down is generated. It will try to distinguish between a left click, right click or drag. In the current version of viztouch (that I use) it leaves the mouse emulation on. That means that for the first touch it uses the mouse emulation and for the dual and multi touches you will get the raw touchpoints.

It is possible to turn the mouse emulation of by using RegisterTouchWindow(hWnd, TWF_WANTPALM). If you do this, even the normal mouse_up, mouse_down and mouse_move events are enough for a single touch screen. So I would like the option to turn off the mouse emulation in viztouch. And maybe an extra mode, like MODE_SINGLETOUCH that just disables the mouse emulation.

Joran 04-18-2012 02:40 AM

Hmm... Did some more experimenting. But only doing the RegisterTouchWindow with TMF_WANTPALM, does not let the mouse_down work as I thought. It will not directly generate a mouse down when the screen is touched. But it still should immediatly generate a touch down.

farshizzo 04-24-2012 05:09 PM

The TMF_WANTPALM flag seems to just disable filtering of palm touches, resulting in slightly lower delays for touch events. I can add an option for using this flag, but I'm still not sure how to disable mouse emulation.

Joran 04-25-2012 01:07 AM

You are right. It does not disable the mouse emulation. But it is less obtrusive when you use the flag. My current project is not usable if the flag is not set, because I will miss too many touch points. So I would really like support for the TMF_WANTPALM flag.

farshizzo 04-25-2012 08:51 AM

The value of the TWF_WANTPALM flag is 2. So for now you can modify by changing line 268 to:

There is also a TWF_FINETOUCH flag. I'm not sure how useful it is, but I'll probably add support for that as well.

All times are GMT -7. The time now is 12:14 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Copyright 2002-2018 WorldViz LLC