#include <Camera.h>
Public Member Functions | |
Camera (Math::Vector3d pos) | |
void | move (float dist) |
void | strafe (float dist) |
void | up (float dist) |
void | pitch (float angle, bool limitRotation=false) |
void | yaw (float angle) |
Math::Vector3d | getPosition () const |
Math::Vector3d | getViewDirection () const |
void | transform () const |
|
Constructs a new Camera with the given world position. By default the Camera is looking along the negative Z-axis, with the pitch and yaw angles set to 0.
|
|
Returns the world position of the Camera.
|
|
Returns the normalized view direction vector of the Camera.
|
|
Moves the Camera forward or backward according to the orientation and the given distance. Positive distance -> forward. Negative distance -> backward.
|
|
Increases the pitch angle with the given angle. Positive angle -> clockwise around the X-axis. Negative angle -> counter-clockwise around the X-axis.
|
|
Moves the Camera left or right according to the orientation and the given distance. Positive distance -> right. Negative distance -> left.
|
|
Transforms the Camera according to the position and the orientation. |
|
Moves the Camera up or down according to the orientation and the given distance. Positive distance -> up. Negative distance -> down.
|
|
Increases the yaw angle with the given angle. Positive angle -> clockwise around the Y-axis. Negative angle -> counter-clockwise around the Y-axis.
|