SimpleGL  1.1.0
A framework for platform independent rendering
Static Public Member Functions | List of all members
sgl::View Class Reference

This class contains static methods to calculate view matrices. More...

#include <transform.hpp>

Static Public Member Functions

static glm::mat4 identity ()
 Returns an identity matrix. More...
 
static glm::mat4 lookAt (glm::vec3 eye, glm::vec3 center, glm::vec3 up)
 Calculates a viewing matrix derived from an eye point, a reference point indicating the center of the scene, and an UP vector. More...
 
static glm::mat4 lookAt (float eyeX, float eyeY, float eyeZ, float centerX, float centerY, float centerZ, float upX, float upY, float upZ)
 Calculates a viewing matrix derived from an eye point, a reference point indicating the center of the scene, and an UP vector. More...
 
static glm::mat4 lookAt (Camera camera)
 Calculates a viewing matrix from a camera. More...
 

Detailed Description

This class contains static methods to calculate view matrices.

Definition at line 216 of file transform.hpp.

Member Function Documentation

glm::mat4 sgl::View::identity ( )
static

Returns an identity matrix.

Returns
The identity matrix.

Definition at line 77 of file transform.cpp.

glm::mat4 sgl::View::lookAt ( glm::vec3  eye,
glm::vec3  center,
glm::vec3  up 
)
static

Calculates a viewing matrix derived from an eye point, a reference point indicating the center of the scene, and an UP vector.

Parameters
eyeSpecifies the position of the eye point.
centerSpecifies the position of the reference point.
upSpecifies the direction of the up vector.
Returns
The calculated lookAt-Matrix.

Definition at line 81 of file transform.cpp.

glm::mat4 sgl::View::lookAt ( float  eyeX,
float  eyeY,
float  eyeZ,
float  centerX,
float  centerY,
float  centerZ,
float  upX,
float  upY,
float  upZ 
)
static

Calculates a viewing matrix derived from an eye point, a reference point indicating the center of the scene, and an UP vector.

Parameters
eyeXSpecifies the X-position of the eye point.
eyeYSpecifies the Y-position of the eye point.
eyeZSpecifies the Z-position of the eye point.
centerXSpecifies the X-position of the reference point.
centerYSpecifies the Y-position of the reference point.
centerZSpecifies the Z-position of the reference point.
upXSpecifies the X-direction of the up vector.
upYSpecifies the Y-direction of the up vector.
upZSpecifies the Z-direction of the up vector.
Returns
The calculated lookAt-Matrix.

Definition at line 85 of file transform.cpp.

glm::mat4 sgl::View::lookAt ( Camera  camera)
static

Calculates a viewing matrix from a camera.

Parameters
cameraThe camera to use.

Definition at line 89 of file transform.cpp.


The documentation for this class was generated from the following files: