core  array_cache  math  swrast  swrast_setup  tnl  tnl_dd 
Main Page   Data Structures   File List   Data Fields   Globals   Related Pages  

rastpos.c File Reference

Raster position operations. More...

#include "glheader.h"
#include "colormac.h"
#include "context.h"
#include "feedback.h"
#include "light.h"
#include "macros.h"
#include "rastpos.h"
#include "state.h"
#include "simple_list.h"
#include "mtypes.h"
#include "math/m_matrix.h"

Initialization

void _mesa_init_rastpos (GLcontext *ctx)
 Initialize the context current raster position information. More...


Functions

GLuint viewclip_point (const GLfloat v[])
 Clip a point against the view volume. More...

GLuint viewclip_point_z (const GLfloat v[])
 Clip a point against the far/near Z clipping planes. More...

GLuint userclip_point (GLcontext *ctx, const GLfloat v[])
 Clip a point against the user clipping planes. More...

void shade_rastpos (GLcontext *ctx, const GLfloat vertex[4], const GLfloat normal[3], GLfloat Rcolor[4], GLfloat Rspec[4], GLfloat *Rindex)
 This has been split off to allow the normal shade routines to get a little closer to the vertex buffer, and to use the GLvector objects directly. More...

void compute_texgen (GLcontext *ctx, const GLfloat vObj[4], const GLfloat vEye[4], const GLfloat normal[3], GLuint unit, GLfloat texcoord[4])
 Do texgen needed for glRasterPos. More...

void raster_pos4f (GLcontext *ctx, GLfloat x, GLfloat y, GLfloat z, GLfloat w)
 Set the raster position for pixel operations. More...

void GLAPIENTRY _mesa_RasterPos2d (GLdouble x, GLdouble y)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2f (GLfloat x, GLfloat y)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2i (GLint x, GLint y)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2s (GLshort x, GLshort y)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3d (GLdouble x, GLdouble y, GLdouble z)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3f (GLfloat x, GLfloat y, GLfloat z)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3i (GLint x, GLint y, GLint z)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3s (GLshort x, GLshort y, GLshort z)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w)
 Calls raster_pos4f(). More...

void GLAPIENTRY _mesa_RasterPos4i (GLint x, GLint y, GLint z, GLint w)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4s (GLshort x, GLshort y, GLshort z, GLshort w)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2dv (const GLdouble *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2fv (const GLfloat *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2iv (const GLint *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos2sv (const GLshort *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3dv (const GLdouble *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3fv (const GLfloat *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3iv (const GLint *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos3sv (const GLshort *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4dv (const GLdouble *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4fv (const GLfloat *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4iv (const GLint *v)
 Calls _mesa_RasterPos4f(). More...

void GLAPIENTRY _mesa_RasterPos4sv (const GLshort *v)
 Calls _mesa_RasterPos4f(). More...

void window_pos3f (GLfloat x, GLfloat y, GLfloat z)
 All glWindowPosMESA and glWindowPosARB commands call this function to update the current raster position. More...

void window_pos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w)
void GLAPIENTRY _mesa_WindowPos2dMESA (GLdouble x, GLdouble y)
void GLAPIENTRY _mesa_WindowPos2fMESA (GLfloat x, GLfloat y)
void GLAPIENTRY _mesa_WindowPos2iMESA (GLint x, GLint y)
void GLAPIENTRY _mesa_WindowPos2sMESA (GLshort x, GLshort y)
void GLAPIENTRY _mesa_WindowPos3dMESA (GLdouble x, GLdouble y, GLdouble z)
void GLAPIENTRY _mesa_WindowPos3fMESA (GLfloat x, GLfloat y, GLfloat z)
void GLAPIENTRY _mesa_WindowPos3iMESA (GLint x, GLint y, GLint z)
void GLAPIENTRY _mesa_WindowPos3sMESA (GLshort x, GLshort y, GLshort z)
void GLAPIENTRY _mesa_WindowPos4dMESA (GLdouble x, GLdouble y, GLdouble z, GLdouble w)
void GLAPIENTRY _mesa_WindowPos4fMESA (GLfloat x, GLfloat y, GLfloat z, GLfloat w)
void GLAPIENTRY _mesa_WindowPos4iMESA (GLint x, GLint y, GLint z, GLint w)
void GLAPIENTRY _mesa_WindowPos4sMESA (GLshort x, GLshort y, GLshort z, GLshort w)
void GLAPIENTRY _mesa_WindowPos2dvMESA (const GLdouble *v)
void GLAPIENTRY _mesa_WindowPos2fvMESA (const GLfloat *v)
void GLAPIENTRY _mesa_WindowPos2ivMESA (const GLint *v)
void GLAPIENTRY _mesa_WindowPos2svMESA (const GLshort *v)
void GLAPIENTRY _mesa_WindowPos3dvMESA (const GLdouble *v)
void GLAPIENTRY _mesa_WindowPos3fvMESA (const GLfloat *v)
void GLAPIENTRY _mesa_WindowPos3ivMESA (const GLint *v)
void GLAPIENTRY _mesa_WindowPos3svMESA (const GLshort *v)
void GLAPIENTRY _mesa_WindowPos4dvMESA (const GLdouble *v)
void GLAPIENTRY _mesa_WindowPos4fvMESA (const GLfloat *v)
void GLAPIENTRY _mesa_WindowPos4ivMESA (const GLint *v)
void GLAPIENTRY _mesa_WindowPos4svMESA (const GLshort *v)


Detailed Description

Raster position operations.


Function Documentation

void _mesa_init_rastpos GLcontext   ctx
 

Initialize the context current raster position information.

Parameters:
ctx  GL context.
Initialize the current raster position information in __GLcontextRec::Current, and adds the extension entry points to the dispatcher.

void GLAPIENTRY _mesa_RasterPos2d GLdouble    x,
GLdouble    y
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2dv const GLdouble *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2f GLfloat    x,
GLfloat    y
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2fv const GLfloat *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2i GLint    x,
GLint    y
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2iv const GLint *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2s GLshort    x,
GLshort    y
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos2sv const GLshort *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3d GLdouble    x,
GLdouble    y,
GLdouble    z
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3dv const GLdouble *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3f GLfloat    x,
GLfloat    y,
GLfloat    z
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3fv const GLfloat *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3i GLint    x,
GLint    y,
GLint    z
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3iv const GLint *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3s GLshort    x,
GLshort    y,
GLshort    z
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos3sv const GLshort *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4d GLdouble    x,
GLdouble    y,
GLdouble    z,
GLdouble    w
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4dv const GLdouble *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4f GLfloat    x,
GLfloat    y,
GLfloat    z,
GLfloat    w
 

Calls raster_pos4f().

void GLAPIENTRY _mesa_RasterPos4fv const GLfloat *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4i GLint    x,
GLint    y,
GLint    z,
GLint    w
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4iv const GLint *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4s GLshort    x,
GLshort    y,
GLshort    z,
GLshort    w
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_RasterPos4sv const GLshort *    v
 

Calls _mesa_RasterPos4f().

void GLAPIENTRY _mesa_WindowPos2dMESA GLdouble    x,
GLdouble    y
 

void GLAPIENTRY _mesa_WindowPos2dvMESA const GLdouble *    v
 

void GLAPIENTRY _mesa_WindowPos2fMESA GLfloat    x,
GLfloat    y
 

void GLAPIENTRY _mesa_WindowPos2fvMESA const GLfloat *    v
 

void GLAPIENTRY _mesa_WindowPos2iMESA GLint    x,
GLint    y
 

void GLAPIENTRY _mesa_WindowPos2ivMESA const GLint *    v
 

void GLAPIENTRY _mesa_WindowPos2sMESA GLshort    x,
GLshort    y
 

void GLAPIENTRY _mesa_WindowPos2svMESA const GLshort *    v
 

void GLAPIENTRY _mesa_WindowPos3dMESA GLdouble    x,
GLdouble    y,
GLdouble    z
 

void GLAPIENTRY _mesa_WindowPos3dvMESA const GLdouble *    v
 

void GLAPIENTRY _mesa_WindowPos3fMESA GLfloat    x,
GLfloat    y,
GLfloat    z
 

void GLAPIENTRY _mesa_WindowPos3fvMESA const GLfloat *    v
 

void GLAPIENTRY _mesa_WindowPos3iMESA GLint    x,
GLint    y,
GLint    z
 

void GLAPIENTRY _mesa_WindowPos3ivMESA const GLint *    v
 

void GLAPIENTRY _mesa_WindowPos3sMESA GLshort    x,
GLshort    y,
GLshort    z
 

void GLAPIENTRY _mesa_WindowPos3svMESA const GLshort *    v
 

void GLAPIENTRY _mesa_WindowPos4dMESA GLdouble    x,
GLdouble    y,
GLdouble    z,
GLdouble    w
 

void GLAPIENTRY _mesa_WindowPos4dvMESA const GLdouble *    v
 

void GLAPIENTRY _mesa_WindowPos4fMESA GLfloat    x,
GLfloat    y,
GLfloat    z,
GLfloat    w
 

void GLAPIENTRY _mesa_WindowPos4fvMESA const GLfloat *    v
 

void GLAPIENTRY _mesa_WindowPos4iMESA GLint    x,
GLint    y,
GLint    z,
GLint    w
 

void GLAPIENTRY _mesa_WindowPos4ivMESA const GLint *    v
 

void GLAPIENTRY _mesa_WindowPos4sMESA GLshort    x,
GLshort    y,
GLshort    z,
GLshort    w
 

void GLAPIENTRY _mesa_WindowPos4svMESA const GLshort *    v
 

void compute_texgen GLcontext   ctx,
const GLfloat    vObj[4],
const GLfloat    vEye[4],
const GLfloat    normal[3],
GLuint    unit,
GLfloat    texcoord[4]
[static]
 

Do texgen needed for glRasterPos.

Parameters:
ctx  rendering context
vObj  object-space vertex coordinate
vEye  eye-space vertex coordinate
normal  vertex normal
unit  texture unit number
texcoord  incoming texcoord and resulting texcoord

void raster_pos4f GLcontext   ctx,
GLfloat    x,
GLfloat    y,
GLfloat    z,
GLfloat    w
[static]
 

Set the raster position for pixel operations.

All glRasterPos command call this function to update the current raster position.

Parameters:
ctx  GL context.
x  x coordinate for the raster position.
y  y coordinate for the raster position.
z  z coordinate for the raster position.
w  w coordinate for the raster position.
See also:
Called by _mesa_RasterPos4f().
Flushes the vertices, transforms and clips the vertex coordinates, and finally sets the current raster position and associated data in __GLcontextRec::Current. When in selection mode calls _mesa_update_hitflag() with the current raster position.

void shade_rastpos GLcontext   ctx,
const GLfloat    vertex[4],
const GLfloat    normal[3],
GLfloat    Rcolor[4],
GLfloat    Rspec[4],
GLfloat *    Rindex
[static]
 

This has been split off to allow the normal shade routines to get a little closer to the vertex buffer, and to use the GLvector objects directly.

Parameters:
ctx  the context
vertex  vertex location
normal  normal vector
Rcolor  returned color
Rspec  returned specular color (if separate specular enabled)
Rindex  returned color index

GLuint userclip_point GLcontext   ctx,
const GLfloat    v[]
[static]
 

Clip a point against the user clipping planes.

Parameters:
ctx  GL context.
v  vertex vector describing the point to clip.
Returns:
zero if the point was clipped, or one otherwise.

GLuint viewclip_point const GLfloat    v[] [static]
 

Clip a point against the view volume.

Parameters:
v  vertex vector describing the point to clip.
Returns:
zero if outside view volume, or one if inside.

GLuint viewclip_point_z const GLfloat    v[] [static]
 

Clip a point against the far/near Z clipping planes.

Parameters:
v  vertex vector describing the point to clip.
Returns:
zero if outside view volume, or one if inside.

void window_pos3f GLfloat    x,
GLfloat    y,
GLfloat    z
[static]
 

All glWindowPosMESA and glWindowPosARB commands call this function to update the current raster position.

void window_pos4f GLfloat    x,
GLfloat    y,
GLfloat    z,
GLfloat    w
[static]
 


Generated on Sun May 16 15:55:12 2004 for Mesa Core by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001