Little problem with gluUnProject

I finally got gluUnProject working, it works great, but there is yet a little problem about it. I calculate 3d position of place where i clicked, but when i move camera the position changes.
I get the modelview matrix and stuff right after moving camera(glTranslatef and glRotatef) and calculate the position just when i click.

Hi !

I am not sure what the problem is, yes it does change when you change the camera, but that’s expected, I mean you change the view when you move the camera.

What you do need to look out for is the usual problem with unproject/project, the Z value is tricky to get it right.

Mikael