

real-time mouse gesture recognition
Hey Forum
Over a year ago I developed a theoretic program for gesture recognition for game maker. However my programming wasn't really up for the task back then, so unfortunately it was left to rust. However I decided to dig out the old theory, give it a shot and found that within 30 minutes, I had a working gesture recognition program.
I then proceeded to make it extra user friendly and even allow the gestures to become real-time ( which was the hard part, but means the user does not need to hold down any button to signal he/she is `gesturing` ). After lots of final touches, we have what is known today as GM-RMG
What are Mouse Gestures?
Think as Mouse gestures as sign language, you move your arms in a certain manner, and the other person understands. Like-wise, using Mouse Gestures you are able to communicate with the computer ( tell it what to do ) using the movement of your cursor
Using GM-RMG
Use of GM-RMG is extremly easy, infact there are only 3 functions, and 99% of the time you'll only use two of them
{ gestures_enable( enable, trigger ) ;
// `Trigger` is the mouse/keyboard button which the user should hold down to signal they are `gesturing`
// use mb_none for `real-time` ( see 1st paragraph for what `real-time` means )
if gestures_get_enabled() = true
{ /* Return if Gestures are enabled */ }
if gestures_check( 'left', 'right', 'left', 'right' ) = true
{ /* return if cursor has moved `left right, left right.
You can enter up to 16 arguments :) */ }
//which could also be written as: ( Note, always use 360, not 0 ) :)
if gestures_check( 180, 360, 180, 360 ) = true
{ /* do this */ }
// There you have it :)
}Download ( Version 2.1 )
- Bundle Zip ( Includes, Resource File, Tech Demo, Example GMK and HTML Help File )
Mirror ( MediaFire )
Mirror ( FreeFileHosting )
Mirror ( MegaUpload )
Edited by Danny Joseph, 03 May 2011 - 10:43 AM.











