Projects world space coordinates to object space.
OpenGL C bindings library: libGL.a
int gluUnProject(GLdouble WindowX, GLdouble WindowY, GLdouble WindowZ, const GLdouble ModelMatrix[16], const GLdouble ProjectMatrix[16], const GLint Viewport[4], GLdouble *ObjX, GLdouble *ObjY, GLdouble *ObjZ)
The gluUnProject subroutine maps the specified window coordinates into object space coordinates using the ModelMatrix, ProjectMatrix, and Viewport parameter values provided. Results are stored in ObjX, ObjY, and ObjZ. A return value of GL_TRUE indicates success, and GL_FALSE indicates failure.
GL_TRUE | Indicates the projection succeeded. |
GL_FALSE | Indicates the projection failed. |
/usr/include/GL/gl.h | Contains C language constraints, variable type definitions, and ANSI function prototypes for OpenGL. |
The glGet subroutine, gluProject subroutine.