core | glapi | vbo | math | shader | swrast | swrast_setup | tnl | tnl_dd

m_vector.c File Reference

#include "main/glheader.h"
#include "main/imports.h"
#include "main/macros.h"
#include "m_vector.h"

Functions

void _mesa_vector4f_clean_elem (GLvector4f *vec, GLuint count, GLuint elt)
 Given a vector [count][4] of floats, set all the [][elt] values to 0 (if elt = 0, 1, 2) or 1.0 (if elt = 3).
void _mesa_vector4f_init (GLvector4f *v, GLbitfield flags, GLfloat(*storage)[4])
 Initialize GLvector objects.
void _mesa_vector4f_alloc (GLvector4f *v, GLbitfield flags, GLuint count, GLuint alignment)
 Initialize GLvector objects and allocate storage.
void _mesa_vector4f_free (GLvector4f *v)
 Vector deallocation.
void _mesa_vector4f_print (const GLvector4f *v, const GLubyte *cullmask, GLboolean culling)
 For debugging.

Variables

static const GLubyte size_bits [5]


Function Documentation

void _mesa_vector4f_alloc ( GLvector4f v,
GLbitfield  flags,
GLuint  count,
GLuint  alignment 
)

Initialize GLvector objects and allocate storage.

Parameters:
v the vector object
flags bitwise-OR of VEC_* flags
count number of elements to allocate in vector
alignment desired memory alignment for the data (in bytes)

void _mesa_vector4f_clean_elem ( GLvector4f vec,
GLuint  count,
GLuint  elt 
)

Given a vector [count][4] of floats, set all the [][elt] values to 0 (if elt = 0, 1, 2) or 1.0 (if elt = 3).

void _mesa_vector4f_free ( GLvector4f v  ) 

Vector deallocation.

Free whatever memory is pointed to by the vector's storage field if the VEC_MALLOC flag is set. DO NOT free the GLvector object itself, though.

void _mesa_vector4f_init ( GLvector4f v,
GLbitfield  flags,
GLfloat *  storage[4] 
)

Initialize GLvector objects.

Parameters:
v the vector object to initialize.
flags bitwise-OR of VEC_* flags
storage pointer to storage for the vector's data

void _mesa_vector4f_print ( const GLvector4f v,
const GLubyte *  cullmask,
GLboolean  culling 
)

For debugging.


Variable Documentation

const GLubyte size_bits[5] [static]

Initial value:


Generated on Sun Sep 27 06:47:50 2009 for Mesa math module by  doxygen 1.5.4