#include <Camera.h>
Public Member Functions | |
virtual const RTTI & | getType () const |
Camera (float AspectRatio, float Near, float Far, float Fovy) | |
void | drawFrustum () const |
Ray | getWorldRayFromScreenPos (int xScreen, int yScreen) const |
void | setProjectionMatrix () const |
Static Public Member Functions | |
static Camera * | getMainCamera () |
static void | setMainCamera (Camera *cam) |
Static Public Attributes | |
static const RTTI | TYPE |
Protected Attributes | |
CameraProjectionTypeEnum | projectionType |
float | aspectRatio |
float | fovy |
float | _near |
float | _far |
Static Protected Attributes | |
static Camera * | mainCamera = NULL |
Base class for a Camera Component of a GameObject. Used by the Scene server of the engine and accessible to the user for eg. ray-casting.
void Camera::drawFrustum | ( | ) | const |
Draws a wireframe frustum. Used to debug.
static Camera* Camera::getMainCamera | ( | ) | [inline, static] |
Get the camera from which the scene is rendered.
Ray Camera::getWorldRayFromScreenPos | ( | int | xScreen, | |
int | yScreen | |||
) | const |
Construct a world space ray from a position on the screen.
void Camera::setProjectionMatrix | ( | ) | const |
Set the camera's projection matrix as OpenGL's projection matrix. Used internaly.
Camera * Camera::mainCamera = NULL [static, protected] |
Static member to acces the camera from which the scene is renderer.