Mouse Class
Does Anyone have any Idea how you would scan the position of the mouse from within a class?
Example:
Class Mouse
{
Public:
Scan(); // this is what I want.
Private:
int mousex, mousey; // Mouse coords.
}
Mouse::Scan()
{
// In here the mouse coords would be stored in mousex/mousey.
}
Did that make sense?
(P.S. I Am STRONGLY against using GLUT, even though it does have mouse functions)
-----------------------------
Blue*Omega
(Insert Witty Quote Here)
// Tojiart
Check out directinput...
||--------------------------||Black Hole Productionshttp://bhp.nydus.netResident expert on stuffmax621@barrysworld.com||--------------------------||
SDL! the 1.1 develpment(stable) has opengl routines much like glut, but they are faster and make porting to other operating systems really easy.
SDL_PumpEvents();
SDL_GetMouseState(&mouse_x, &mouse_y);
it can be that easy
SDL_PumpEvents();
SDL_GetMouseState(&mouse_x, &mouse_y);
it can be that easy
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement