PDA

View Full Version : OT - get mouse position with high precision



Morglum
12-13-2001, 07:02 AM
Hi !

In my opengl app I use the mouse to let the user look in any direction. I use glutMotionFunc to achieve this. Unfortunately, this gives me only 1-pixel precision. I would like to get the mouse position *before* it is converted into screen coordinates. Do you know any API able to do this ? What do they use in games ?

Thanks, and sorry for the poorly opengl-related topic,
but an answer to this question might help many opengl programmers http://www.opengl.org/discussion_boards/ubb/wink.gif !

chowe6685
12-13-2001, 08:43 AM
if you are on a windows systen you could always use the API or DirectInput

Morglum
12-14-2001, 03:38 AM
for directinput, do you know if there is a tutorial ?

Thanks !

12-17-2001, 12:04 AM
There is an opengl w/direct input using the mouse and keyboard on nehe.gamedev.net.

Morglum
12-17-2001, 12:39 AM
Thanks ! http://www.opengl.org/discussion_boards/ubb/smile.gif