The gluProject function maps object coordinates to window coordinates.
int gluProject(
GLdouble objx,
GLdouble objy,
GLdouble objz,
const GLdouble modelMatrix[16],
const GLdouble projMatrix[16],
const GLint viewport[4],
GLdouble * winx,
GLdouble * winy,
GLdouble * winz
);
The gluProject function transforms the specified object coordinates into window coordinates using modelMatrix, projMatrix, and viewport. The result is stored in winx, winy, and winz. A return value of GL_TRUE indicates success, and GL_FALSE indicates failure.
Windows NT: Use version 3.5 and later.
Windows: Use Windows 95 and later.
Windows CE: Unsupported.
Header: Declared in glu.h.
Import Library: Link with glu32.lib.
glGetDoublev, glGetIntegerv, gluUnProject