Functions

wavepacket-lib/lib/geometry/frustum.cpp File Reference

#include "frustum.h"
#include <math.h>
Include dependency graph for wavepacket-lib/lib/geometry/frustum.cpp:

Go to the source code of this file.

Functions

static void setFrustumPlane (frustum_t &f, frustum_t::ePlane index, const point3d_t &a, const point3d_t &b, const point3d_t &p) throw ()
static float getTimeWhenLineIntersectsPlane (const plane_t &P, const point3d_t &p0, const point3d_t &pt) throw ()
bool createViewFrustum (const point3d_t &position, const point3d_t &facing, const point3d_t &up, float fovyRadians, float zNear, float zFar, float aspect, frustum_t &f) throw ()
 create a view frustum given basic geometric information.

Function Documentation

static void setFrustumPlane ( frustum_t f,
frustum_t::ePlane  index,
const point3d_t a,
const point3d_t b,
const point3d_t p 
) throw () [static]
Parameters:
a one vector in plane
b another vector in plane
p a point in the plane

Definition at line 49 of file wavepacket-lib/lib/geometry/frustum.cpp.

static float getTimeWhenLineIntersectsPlane ( const plane_t P,
const point3d_t p0,
const point3d_t pt 
) throw () [static]

Definition at line 72 of file wavepacket-lib/lib/geometry/frustum.cpp.

bool createViewFrustum ( const point3d_t position,
const point3d_t facing,
const point3d_t up,
float  fovyRadians,
float  zNear,
float  zFar,
float  aspect,
frustum_t frustum 
) throw ()

create a view frustum given basic geometric information.

Keep in mind, this uses standard OpenGL right-handed coordinates, with Y being the usual up direction, and x and z in the plane of the ground.

Parameters:
fovyRadians field of view, Y

Definition at line 219 of file wavepacket-lib/lib/geometry/frustum.cpp.