PDA

View Full Version : mouse problem!!!



02-01-2004, 07:24 AM
hi everyone..
how can i get the coordinate from a screen..while click..and during the motion...
from a mouse..
as in case of GLUT...we have two different function for mouse motion and mouse click..which directly give coordinates..
but how can i do same without using GLUT...as i am following nehe's tutorails..and it will be really tough to switch from a non-console progame to a consol ( will it really be?? )
actually i have cube on screen..which i want to rotate with the help of mouse...how can it be done?? (without using glut)..
if someone help with little code example..i will really be thaknful..
waiting for replies..
-prafs

mikael_aronsson
02-01-2004, 11:47 AM
The mouse cursor/coordinates have nothing to do with OpenGL so you will not find it there.

If you decide not to use glut, then you will have to use something else to create the window that will contain the rendering context and that "else" will give you support for mouse handling, so it is difficult to give you an answer without any knowledge on what you are going to use, Win32, xlib, Fltk, FOX, Qt...bla bla bla...

Mikael

nexusone
02-01-2004, 04:28 PM
Well it depends on what operating system you are using, the mouse functions are diffrent for each OS.

Only using GLUT can you use the same function calls on any system for the mouse.