PDA

View Full Version : set mouse coord



Dentist
02-20-2002, 11:04 PM
I'm using GLUT + win98 + Borland C++ Builder 5

Hi Does anyone know if GLUT API contains a call to reset the mouse coord to some x,y position ??.
I need to allow continuous 360 degree viewer rotation ala Quake. I've tried embedding _asm stuff but it freaks the OS out and crashes.

02-21-2002, 12:44 AM
Try using directinput... it's better to rule

marcus256
02-21-2002, 02:40 AM
Try GLFW (http://hem.passagen.se/opengl/glfw/) , it's better to kick ass http://www.opengl.org/discussion_boards/ubb/wink.gif

glfwDisable( GLFW_MOUSE_CURSOR )

gives you an "infinite" mouse range (range +/- 2^31). If that is not enough, use

glfwSetMousePos( 0, 0 )

...every now and then.



[This message has been edited by marcus256 (edited 02-21-2002).]

Dentist
02-21-2002, 09:09 PM
Thanks bebbr

I don't really know what directinput is bu I will look into it, I assume it is a function in the GLUT api ??

Ben

Dentist
02-21-2002, 09:13 PM
Cheers marcus256, I will check this out for sure. Would I be right in saying that it is an alternative to glut. Anyway I will do some reading.

Thanks again

Ben

Mr_Smith
02-23-2002, 08:23 AM
Ive tried using Direct input but have several probs,
How do i hide the mouse http://www.opengl.org/discussion_boards/ubb/frown.gif
and How do i reset the mouse to a fixed pos like 0,0?