Jump to content
  • Advertisement

Archived

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

Raeldor

Selecting 3D objects with the mouse

This topic is 5584 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi all, I have implemented a mouse in my game using an untransformed polygon, which I move my passing the DirectInput mouse events. Seems to work pretty well. My question is, when clicking on the screen how do I find out which object I am clicking on. I assume there it must be some kind of Ray intersection test with the objects in the scene, but how do I calculate the Ray vector etc. from the screen position? Many Thanks Rael

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
I know this is for directx but check out this thread, I use a modified version of it and it works very well.

http://www.opengl.org/discussion_boards/ubb/Forum2/HTML/000905.html

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!