Please help me with this (more on point selection)

I would really appreciate it if someone could give me an example of code or point me to a tutorial for this.
Problem:
Imagine a cube defined with glVertex commands.
Then the point of the cube are drawn again. I want the user to be able to select/highligh a point if he click on or close to it.
Please help… :frowning:
Luke

go to gametutorials.com and look around, there; there is a tutorial showing how to make selections work in GL.
(its a very easy one)

All I can find there is selecting object, which I know how to do… what I can’t do is having an object and letting the user select it’s components… :frowning: the exmaple on that site uses selection buffer, which is not what is needed in this case…

a As has already been suggested, you need to look for references on Ray casting (perhaps you could try Google?). To do vert/ray intersections you probably want to look for sphere/ray intersection algorithms, or just triangle/ray intersections. You can probably find what you need here

b This is not an Opengl question, this is a 3D math question. Perhaps you should look for a mathematics forum and/or web sites.

c Please stop posting beginner questions in the Advanced Coding forums.

rgps, sorry, didn’t realize it was a beginner question…