Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Getting mouse gestures

This topic is 6060 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I am sure a good number of us have played black and white, and I am asking how ddid they do that?getting the mouse gestures. My guess would be they stored all the mouse x,y coords into some array then perform a series of "unit" tests on those cordinates to determine what gesture was preformed. IE for the circle gesteure, they then draw an imaginary cross to see if if it intersects x many times on the inputed mouse coordinates, if so then it was a circle gesture. Does this sound correct? or did they do it a different way you think? Extremely curious, Shane

Share this post

Link to post
Share on other sites
Short vector mathematics I think. It just pulls around every x-distance travelled, and then looks at the "corner" between that line and the previous line.


Okay, that didn't make any sense. Okay, what it does (I think) is store the distance and speed that mouse travels over the screen. Every n-units (depends on distance and speed) it stores the location of the mouse over the map. It then checks what the angle is between the last drawn "line", and the one before that, and then stores that angle as well (or perhaps only if it was positive or negative)

-Maarten Leeuwrik

Edited by - ronin_54 on February 21, 2002 12:36:44 PM

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!