#include <CylindricCamera.h>
Definition at line 16 of file CylindricCamera.h.
Public Member Functions | |
CylindricCamera (Vector3D pos, Vector3D up, float height, float radius, int resX, int resY) | |
Initializes the camera with its positon, up vector, radius, x resolution and y resolution. | |
virtual | ~CylindricCamera () |
virtual Ray | InitRay (float x, float y) |
Creates a new ray that's origin is the position of the camera, and that points towards the Point (x,y) on the surrounding cylinder. | |
Private Attributes | |
Vector3D | pos |
The position of the camera. | |
Vector3D | up |
The up vector of the camera. | |
float | height |
The height of the cylinder that surrounds the camera. | |
float | radius |
The radius of the surrounding cylinder. | |
float | invResX |
The inverse of the resulution in x-direction. Used as helper. | |
float | invResY |
The inverse of the resulution in y-direction. Used as helper. |
CylindricCamera::CylindricCamera | ( | Vector3D | pos, | |
Vector3D | up, | |||
float | height, | |||
float | radius, | |||
int | resX, | |||
int | resY | |||
) | [inline] |
Initializes the camera with its positon, up vector, radius, x resolution and y resolution.
Definition at line 60 of file CylindricCamera.h.
virtual CylindricCamera::~CylindricCamera | ( | ) | [inline, virtual] |
Definition at line 70 of file CylindricCamera.h.
Ray CylindricCamera::InitRay | ( | float | x, | |
float | y | |||
) | [inline, virtual] |
Creates a new ray that's origin is the position of the camera, and that points towards the Point (x,y) on the surrounding cylinder.
Implements Camera.
Definition at line 78 of file CylindricCamera.h.
References Ray::dir, height, invResX, invResY, Vector3D::Normalized(), Ray::org, pos, radius, Vector3D::x(), Vector3D::y(), and Vector3D::z().
Vector3D CylindricCamera::pos [private] |
The position of the camera.
Vector3D pos
Definition at line 22 of file CylindricCamera.h.
Referenced by InitRay().
Vector3D CylindricCamera::up [private] |
float CylindricCamera::height [private] |
The height of the cylinder that surrounds the camera.
float height
Definition at line 34 of file CylindricCamera.h.
Referenced by InitRay().
float CylindricCamera::radius [private] |
The radius of the surrounding cylinder.
float radius
Definition at line 40 of file CylindricCamera.h.
Referenced by InitRay().
float CylindricCamera::invResX [private] |
The inverse of the resulution in x-direction. Used as helper.
float invResX
Definition at line 46 of file CylindricCamera.h.
Referenced by CylindricCamera(), and InitRay().
float CylindricCamera::invResY [private] |
The inverse of the resulution in y-direction. Used as helper.
float invResY
Definition at line 52 of file CylindricCamera.h.
Referenced by CylindricCamera(), and InitRay().