*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->Tru64 Unix man pages -> gluProject (3)              
Title
Content
Arch
Section
 

Contents


gluProject()                                         gluProject()


NAME    [Toc]    [Back]

       gluProject - map object coordinates to window coordinates

SYNOPSIS    [Toc]    [Back]

       GLint gluProject(
               GLdouble objX,
               GLdouble objY,
               GLdouble objZ,
               const GLdouble *model,
               const GLdouble *proj,
               const GLint *view,
               GLdouble* winX,
               GLdouble* winY,
               GLdouble* winZ );

PARAMETERS    [Toc]    [Back]

       Specify  the  object  coordinates.   Specifies the current
       modelview matrix (as from a glGetDoublev() call).   Specifies
  the  current  projection matrix (as from a glGetDoublev()
 call).  Specifies the current viewport (as  from  a
       glGetIntegerv() call).  Return the computed window coordinates.

DESCRIPTION    [Toc]    [Back]

       gluProject() transforms the specified  object  coordinates
       into  window  coordinates using model, proj, and view. The
       result is stored in winX, winY, and winZ. A  return  value
       of  GL_TRUE  indicates success, a return value of GL_FALSE
       indicates failure.

       To compute the coordinates, let v  =  (objX,  objY,  objZ,
       1.0)  represented  as  a  matrix with 4 rows and 1 column.
       Then gluProject() computes v^prime as follows: V^prime = P
       times M times v

       where  P  is  the current projection matrix proj, M is the
       current modelview matrix  model  (both  represented  as  4
       times 4 matrices in column-major order) and 'times' represents
 matrix multiplication.

       The window coordinates are then computed as follows:  winX
       =  view(0) + view(2) * (v^prime(0) + 1) / 2 winY = view(1)
       + view(3) * (v^prime(1) + 1) / 2 winZ = (v^prime(2) + 1) /
       2

SEE ALSO    [Toc]    [Back]

      
      
       glGet(3), gluUnProject(3)



                                                     gluProject()
[ Back ]
 Similar pages
Name OS Title
gluunproject4 IRIX map window and clip coordinates to object coordinates
gluunproject IRIX map window coordinates to object coordinates
gluUnProject Tru64 map window coordinates to object coordinates
gldepthrange IRIX specify mapping of depth values from normalized device coordinates to window coordinates
glDepthRange Tru64 specify mapping of depth values from normalized device coordinates to window coordinates
curs_getyx IRIX get curses cursor and window coordinates
getyx OpenBSD get curses cursor and window coordinates
getbegyx FreeBSD get curses cursor and window coordinates
getyx FreeBSD get curses cursor and window coordinates
getbegyx OpenBSD get curses cursor and window coordinates
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service