View Full Version : Selection/Feedback

02-16-2000, 07:08 PM
Can anyone give me some hints/pseudocode on how to pick/select a single object to do indiviual rotation/translation among multiple object models on the screen?
Even I have read the red book, I still have no idea about that.

02-17-2000, 02:02 AM
Forget selection. You were maybe misled by this term.
What you are going to do, is push the modelview matrix on the stack, set it to desired rot/tran values, and draw the object. After that pop the matrix, and again do that with the next object.
See glPushMatrix/glPopMatrix, and review the section on matrix manipulation on the specs.

02-17-2000, 02:09 AM
Ops! Sorry maybe I misundertood your request... You wanna do selection, right? so the part on rotating things is not the question...?
Okay, enter the advanced forum, and look for some selection topic: it's already there, with the info you need. http://www.opengl.org/discussion_boards/ubb/smile.gif