Archived

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

ju

cursors and icons...

Recommended Posts

Hello, How can I define my own cursor with openGL? How can I apply an icon to my window?(I think it''s perhaps not an openGL function...) Thanks ju

Share this post


Link to post
Share on other sites
The icon and cursor can be done using the win32 api, not sure exactly how....

But the cursor can also be done in opengl using a textured quad. Bassicly you hide the windows cursor, then you read the mouse coordinates from the windows message loop and you dra your textured quad at that location.

Share this post


Link to post
Share on other sites
Its a win32 resource thing. Its not too hard to do, just mess around with MVC++''s resource thing-a-mah-jiggers (my command of the English language is sometime bewildering )

------------------------------
Trent (ShiningKnight)
E-mail me
"Whoso is a man, is a nonconformist"
--Ralph Waldo Emerson

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
just create a cursor in Microangelo( or other cursor maker).
then jsut use this command....
HCURSOR mycursor=LoadCursorFromFile("mycursor.cur";
when you want to display it use..
SetCursor(mycursor)
when you want the arrow back do this...
SetCursor(IDC_ARROW);
it *CAN* be an animated cursor too.

Share this post


Link to post
Share on other sites