Raylib C++  1.0.0
Encapsulates the raylib library
Public Member Functions | List of all members
raylib::RlCamera Class Reference

Encapsulation of the raylib Camera3D. More...

#include <RlCamera.hpp>

Collaboration diagram for raylib::RlCamera:
Collaboration graph

Public Member Functions

 RlCamera ()
 Empty constructor who doesn't initialize the camera. More...
 
 RlCamera (const Vector3f &position, const Vector3f &target, const Vector3f &lookingPoint, const float &fovy=45, const CameraProjection &projection=CAMERA_PERSPECTIVE, const CameraMode &cameraMode=CAMERA_FREE)
 Construct a new RlCamera object. More...
 
void update ()
 Update the camera, needed to move the camera. More...
 
void reset ()
 Reset the camera to the initial state of the constructor. More...
 
void setPosition (const Vector3f &position)
 Set the position of the camera. More...
 
void setTarget (const Vector3f &target)
 Set the target of the camera (Camera looking at point) More...
 
void setProjection (const CameraProjection &projection)
 Set the camera projection type. More...
 
void setFov (const float &fovy)
 Set the fovy of the camera (Camera field-of-view Y) More...
 
void setCameraMode (const CameraMode &mode)
 Set the camera mode. More...
 
const Camera3D & get () const
 Get the 3d camera. More...
 
Matrix geMatrix ()
 Get the matrix of the camera. More...
 
const CameraMode & getMode () const
 Get the camera mode. More...
 
const Vector3fgetConstructedPosition () const
 Get the position of the camera when construct. More...
 
const Vector3fgetConstructedTarget () const
 Get the target of the camera when construct. More...
 
const Vector3fgetConstructedLookingPoint () const
 Get the looking point of the camera when construct. More...
 
const float & getConstructedFovy () const
 Get the fovy of the camera when construct. More...
 
const CameraProjection & getConstructedProjection () const
 Get the projection of the camera when construct. More...
 
const CameraMode & getConstructedCameraMode () const
 Get the camera mode when construct. More...
 

Detailed Description

Encapsulation of the raylib Camera3D.

Constructor & Destructor Documentation

◆ RlCamera() [1/2]

raylib::RlCamera::RlCamera ( )
inline

Empty constructor who doesn't initialize the camera.

◆ RlCamera() [2/2]

raylib::RlCamera::RlCamera ( const Vector3f position,
const Vector3f target,
const Vector3f lookingPoint,
const float &  fovy = 45,
const CameraProjection &  projection = CAMERA_PERSPECTIVE,
const CameraMode &  cameraMode = CAMERA_FREE 
)
explicit

Construct a new RlCamera object.

Parameters
positionthe position of the camera
targetthe target of the camera (Camera looking at point)
lookingPointthe lookingPoint of the camera (rotation towards target)
fovythe fovy of the camera (Camera field-of-view Y)
projectionthe projection of the camera
See also
CameraProjection
Parameters
cameraModethe mode of the camera
See also
CameraMode
Attention
Don't use this use the RlCameraBuilder instead (please)
See also
RlCameraBuilder
Exceptions
CameraException
Here is the call graph for this function:

Member Function Documentation

◆ geMatrix()

Matrix raylib::RlCamera::geMatrix ( )

Get the matrix of the camera.

Returns
the matrix of the camera

◆ get()

const Camera3D & raylib::RlCamera::get ( ) const

Get the 3d camera.

Returns
the 3d camera
Here is the caller graph for this function:

◆ getConstructedCameraMode()

const CameraMode & raylib::RlCamera::getConstructedCameraMode ( ) const

Get the camera mode when construct.

Returns
the camera mode

◆ getConstructedFovy()

const float & raylib::RlCamera::getConstructedFovy ( ) const

Get the fovy of the camera when construct.

Returns
the fovy of the camera

◆ getConstructedLookingPoint()

const Vector3f & raylib::RlCamera::getConstructedLookingPoint ( ) const

Get the looking point of the camera when construct.

Returns
the looking point vector of the camera

◆ getConstructedPosition()

const Vector3f & raylib::RlCamera::getConstructedPosition ( ) const

Get the position of the camera when construct.

Returns
the position of the camera

◆ getConstructedProjection()

const CameraProjection & raylib::RlCamera::getConstructedProjection ( ) const

Get the projection of the camera when construct.

Returns
the projection of the camera

◆ getConstructedTarget()

const Vector3f & raylib::RlCamera::getConstructedTarget ( ) const

Get the target of the camera when construct.

Returns
the target of the camera

◆ getMode()

const CameraMode & raylib::RlCamera::getMode ( ) const

Get the camera mode.

Returns
the camera mode
Here is the caller graph for this function:

◆ reset()

void raylib::RlCamera::reset ( )

Reset the camera to the initial state of the constructor.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ setCameraMode()

void raylib::RlCamera::setCameraMode ( const CameraMode &  mode)

Set the camera mode.

Parameters
modethe mode of the camera
See also
CameraMode
Here is the call graph for this function:

◆ setFov()

void raylib::RlCamera::setFov ( const float &  fovy)

Set the fovy of the camera (Camera field-of-view Y)

Parameters
fovythe fovy of the camera

◆ setPosition()

void raylib::RlCamera::setPosition ( const Vector3f position)

Set the position of the camera.

Parameters
positionthe position of the camera

◆ setProjection()

void raylib::RlCamera::setProjection ( const CameraProjection &  projection)

Set the camera projection type.

Parameters
projectionthe projection of the camera
See also
CameraProjection

◆ setTarget()

void raylib::RlCamera::setTarget ( const Vector3f target)

Set the target of the camera (Camera looking at point)

Parameters
targetthe target of the camera

◆ update()

void raylib::RlCamera::update ( )

Update the camera, needed to move the camera.

Here is the caller graph for this function:

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