PDA

View Full Version : Pick on screen and computation of coordinates



The mexican
06-17-2004, 03:01 PM
Hello kind people.
Suppose that there is a world coordinate system on screen. You can rotate it and translate it. The information is on MatrixStack. (MODELVIEW mode.)
The user can pick on screen and the coordinates of the cursor at the time of pick are known. I want somehow to compute the coordinates of the picked point.
With other words, how can I compute the coordinates in modelview (x, y, z) of the picked point which has screen coords (x, y).
Many thanks for any help.

06-17-2004, 11:17 PM
A lot of solutions
(but very few are working in my case):
- ogl picking,
- gluUnproject,
- readpixel and back buffer