VTFLib/VTFMathlib.h File Reference

Small math library used by VTFLib. More...

#include "stdafx.h"

Include dependency graph for VTFMathlib.h:

This graph shows which files directly or indirectly include this file:


Classes

class  Vector
 Simple 3D Vector class. More...
class  VectorAligned
 Simple Aligned 3D Vector class. More...

Defines

#define CACHE_LINE   16
 Alignment size.
#define CACHE_ALIGN   __declspec(align(CACHE_LINE))
 Storage-class information alignment.
#define drand48()   (((vlSingle) rand())/((vlSingle) RAND_MAX))
 Random number generator for the spheremap generation function.

Functions

void VecAdd (Vector *a, Vector *b, Vector *sum)
 Vector addition function.
void VecSub (Vector *a, Vector *b, Vector *diff)
 Vector subtraction function.
void VecScale (Vector *v, vlSingle scale)
 Vector scale function.
vlSingle VecDot (Vector *u, Vector *v)
 Vector dot-product function.
void VecReflect (Vector *axis, Vector *v, Vector *r)
 Vector reflect function.
vlInt Intersect (Vector *v)
 Vector intersect function.

Detailed Description

Small math library used by VTFLib.

A small collection of math functions and defines used by VTFLib.


Define Documentation

#define CACHE_ALIGN   __declspec(align(CACHE_LINE))

Storage-class information alignment.

#define CACHE_LINE   16

Alignment size.

 
#define drand48 (  )     (((vlSingle) rand())/((vlSingle) RAND_MAX))

Random number generator for the spheremap generation function.


Function Documentation

vlInt Intersect ( Vector v  ) 

Vector intersect function.

void VecAdd ( Vector a,
Vector b,
Vector sum 
)

Vector addition function.

vlSingle VecDot ( Vector u,
Vector v 
)

Vector dot-product function.

void VecReflect ( Vector axis,
Vector v,
Vector r 
)

Vector reflect function.

void VecScale ( Vector v,
vlSingle  scale 
)

Vector scale function.

void VecSub ( Vector a,
Vector b,
Vector diff 
)

Vector subtraction function.


Generated on Fri Dec 28 23:26:22 2007 for VTFLib 1.2.7 by  doxygen 1.5.4