Class representing camera object.
More...
#include <Camera.h>
|
| Camera (const Eigen::Vector3d &localization, const Eigen::Vector3d &direction, const Eigen::Vector3d &up) |
|
| Camera (const Eigen::Vector3d &localization, const Eigen::Vector3d &direction, const Eigen::Vector3d &up, Settings_t set) |
|
| ~Camera () |
|
std::shared_ptr< Scene > | getScene () |
|
pixel * | takePhoto () |
|
void | setCamera (const Eigen::Vector3d &localization, const Eigen::Vector3d &direction, const Eigen::Vector3d &up) |
|
Class representing camera object.
Class representing camera object. Controls whole rendering process of the RayMarching lib.
◆ CameraCommands
Enum describing Commands available for the Camera threads
Enumerator |
---|
GENERATE | Generate new Camera rays
|
DRAW | Draw new image buffer
|
◆ Camera() [1/2]
RayMarching::Camera::Camera |
( |
const Eigen::Vector3d & |
localization, |
|
|
const Eigen::Vector3d & |
direction, |
|
|
const Eigen::Vector3d & |
up |
|
) |
| |
|
inline |
Creates new Camera with default settings
- Parameters
-
localization | Vector3d representing Camera position in the space |
direction | Vector3d representing Point at which Camera looks |
up | Vector3d representing normal vector for Camera horizontal plane |
◆ Camera() [2/2]
RayMarching::Camera::Camera |
( |
const Eigen::Vector3d & |
localization, |
|
|
const Eigen::Vector3d & |
direction, |
|
|
const Eigen::Vector3d & |
up, |
|
|
Settings_t |
set |
|
) |
| |
Creates new Camera object
- Parameters
-
localization | Vector3d representing Camera position in the space |
direction | Vector3d representing Point at which Camera looks |
up | Vector3d representing normal vector for Camera horizontal plane |
set | Settings_t structure defining parameters |
◆ ~Camera()
RayMarching::Camera::~Camera |
( |
| ) |
|
◆ applyCommand()
Sends command to the render threads and awaits for the synchronization
- Parameters
-
cmd | CameraCommands command |
◆ getScene()
std::shared_ptr<Scene> RayMarching::Camera::getScene |
( |
| ) |
|
|
inline |
Scene getter
- Returns
- shared pointer owning Scene object
◆ setCamera()
void RayMarching::Camera::setCamera |
( |
const Eigen::Vector3d & |
localization, |
|
|
const Eigen::Vector3d & |
direction, |
|
|
const Eigen::Vector3d & |
up |
|
) |
| |
Moves Camera to a new position
- Parameters
-
localization | Vector3d representing Camera position in the space |
direction | Vector3d representing Point at which Camera looks |
up | Vector3d representing normal vector for Camera horizontal plane |
◆ takePhoto()
pixel * RayMarching::Camera::takePhoto |
( |
| ) |
|
Render frame
- Returns
- unsigned char[3 * WIDTH * HEIGHT] OpenGL RGB 8bit buffer
◆ BACKGROUND
The documentation for this class was generated from the following files:
- src/models/Camera.h
- src/models/Camera.cpp