GLProgramming.com

home :: about :: development guides :: irc :: forums :: search :: paste :: links :: contribute :: code dump

-> Click here to learn how to get live help <-


Manpage of GLRASTERPOS

GLRASTERPOS

Index
 

NAME

glRasterPos2d, glRasterPos2f, glRasterPos2i, glRasterPos2s, glRasterPos3d, glRasterPos3f, glRasterPos3i, glRasterPos3s, glRasterPos4d, glRasterPos4f, glRasterPos4i, glRasterPos4s, glRasterPos2dv, glRasterPos2fv, glRasterPos2iv, glRasterPos2sv, glRasterPos3dv, glRasterPos3fv, glRasterPos3iv, glRasterPos3sv, glRasterPos4dv, glRasterPos4fv, glRasterPos4iv, glRasterPos4sv - specify the raster position for pixel operations

 

C SPECIFICATION

void f3glRasterPos2dfP( GLdouble fIxfP,
   GLfloat fIyfP )
void f3glRasterPos2ifP( GLint fIxfP,
   GLshort fIyfP )
void f3glRasterPos3dfP( GLdouble fIxfP,
   GLfloat fIyfP,
   GLfloat fIzfP )
void f3glRasterPos3ifP( GLint fIxfP,
   GLshort fIyfP,
   GLshort fIzfP )
void f3glRasterPos4dfP( GLdouble fIxfP,
   GLfloat fIyfP,
   GLfloat fIzfP,
   GLfloat fIwfP )
void f3glRasterPos4ifP( GLint fIxfP,
   GLshort fIyfP,
   GLshort fIzfP,
   GLshort fIwfP )

delim $$  

PARAMETERS

f2xfP, f2yfP, f2zfP, f2wfP
Specify the $x$, $y$, $z$, and $w$ object coordinates (if present) for the raster position.
 

C SPECIFICATION

void f3glRasterPos2dvfP( const GLdouble fI*vfP )


void f3glRasterPos2fvfP(
const GLfloat fI*vfP )


void f3glRasterPos2ivfP(
const GLint fI*vfP )


void f3glRasterPos2svfP(
const GLshort fI*vfP )


void f3glRasterPos3dvfP(
const GLdouble fI*vfP )


void f3glRasterPos3fvfP(
const GLfloat fI*vfP )


void f3glRasterPos3ivfP(
const GLint fI*vfP )


void f3glRasterPos3svfP(
const GLshort fI*vfP )


void f3glRasterPos4dvfP(
const GLdouble fI*vfP )


void f3glRasterPos4fvfP(
const GLfloat fI*vfP )


void f3glRasterPos4ivfP(
const GLint fI*vfP )


void f3glRasterPos4svfP(
const GLshort fI*vfP )


 

PARAMETERS

f2vfP
Specifies a pointer to an array of two, three, or four elements, specifying $x$, $y$, $z$, and $w$ coordinates, respectively.
 

DESCRIPTION

The GL maintains a 3D position in window coordinates. This position, called the raster position, is used to position pixel and bitmap write operations. It is maintained with subpixel accuracy. See %f3glBitmapfP, %f3glDrawPixelsfP, and %f3glCopyPixelsfP. The current raster position consists of three window coordinates ($x$, $y$, $z$), a clip coordinate value ($w$), an eye coordinate distance, a valid bit, and associated color data and texture coordinates. The $w$ coordinate is a clip coordinate, because $w$ is not projected to window coordinates. %f3glRasterPos4fP specifies object coordinates $x$, $y$, $z$, and $w$ explicitly. %f3glRasterPos3fP specifies object coordinate $x$, $y$, and $z$ explicitly, while $w$ is implicitly set to 1. %f3glRasterPos2fP uses the argument values for $x$ and $y$ while implicitly setting $z$ and $w$ to 0 and 1. The object coordinates presented by %f3glRasterPosfP are treated just like those of a %f3glVertexfP command: They are transformed by the current modelview and projection matrices and passed to the clipping stage. If the vertex is not culled, then it is projected and scaled to window coordinates, which become the new current raster position, and the %f3GL_CURRENT_RASTER_POSITION_VALIDfP flag is set. If the vertex is culled, then the valid bit is cleared and the current raster position and associated color and texture coordinates are undefined. The current raster position also includes some associated color data and texture coordinates. If lighting is enabled, then %f3GL_CURRENT_RASTER_COLORfP (in RGBA mode) or %f3GL_CURRENT_RASTER_INDEXfP (in color index mode) is set to the color produced by the lighting calculation (see %f3glLightfP, %f3glLightModelfP, and
%f3glShadeModelfP). If lighting is disabled, current color (in RGBA mode, state variable %f3GL_CURRENT_COLORfP) or color index (in color index mode, state variable %f3GL_CURRENT_INDEXfP) is used to update the current raster color. Likewise, %f3GL_CURRENT_RASTER_TEXTURE_COORDSfP is updated as a function of %f3GL_CURRENT_TEXTURE_COORDSfP, based on the texture matrix and the texture generation functions (see %f3glTexGenfP). Finally, the distance from the origin of the eye coordinate system to the vertex as transformed by only the modelview matrix replaces %f3GL_CURRENT_RASTER_DISTANCEfP. Initially, the current raster position is (0, 0, 0, 1), the current raster distance is 0, the valid bit is set, the associated RGBA color is (1, 1, 1, 1), the associated color index is 1, and the associated texture coordinates are (0, 0, 0, 1). In RGBA mode, %f3GL_CURRENT_RASTER_INDEXfP is always 1; in color index mode, the current raster RGBA color always maintains its initial value.  

NOTES

The raster position is modified both by %f3glRasterPosfP and by %f3glBitmapfP. When the raster position coordinates are invalid, drawing commands that are based on the raster position are ignored (that is, they do not result in changes to GL state). Calling %f3glDrawElementsfP, or %f3glDrawRangeElementsfP may leave the current color or index indeterminate. If %f3glRasterPosfP is executed while the current color or index is indeterminate, the current raster color or current raster index remains indeterminate. To set a valid raster position outside the viewport, first set a valid raster position, then call %f3glBitmapfP with NULL as the f2bitmapfP parameter. When the %f3GL_ARB_imagingfP extension is supported, there are distinct raster texture coordinates for each texture unit. Each texture unit's current ratster texture coordinates are updated by %f3glRasterPosfP.  

ERRORS

%f3GL_INVALID_OPERATIONfP is generated if %f3glRasterPosfP is executed between the execution of %f3glBeginfP and the corresponding execution of %f3glEndfP.  

ASSOCIATED GETS

%f3glGetfP with argument %f3GL_CURRENT_RASTER_POSITIONfP
%f3glGetfP with argument %f3GL_CURRENT_RASTER_POSITION_VALIDfP
%f3glGetfP with argument %f3GL_CURRENT_RASTER_DISTANCEfP
%f3glGetfP with argument %f3GL_CURRENT_RASTER_COLORfP
%f3glGetfP with argument %f3GL_CURRENT_RASTER_INDEXfP
%f3glGetfP with argument %f3GL_CURRENT_RASTER_TEXTURE_COORDSfP  

SEE ALSO

%f3glBitmap(3G)fP, %f3glCopyPixels(3G)fP, %f3glDrawArrays(3G)fP, %f3glDrawElements(3G)fP, %f3glDrawRangeElements(3G)fP, %f3glDrawPixels(3G)fP, %f3glTexCoord(3G)fP, %f3glTexGen(3G)fP, %f3glVertex(3G)fP


 

Index

NAME
C SPECIFICATION
PARAMETERS
C SPECIFICATION
PARAMETERS
DESCRIPTION
NOTES
ERRORS
ASSOCIATED GETS
SEE ALSO