My Project
Loading...
Searching...
No Matches
EditorCamera Class Reference

Camera used inside the editor environment. This camera allows free movement and rotation in the scene to inspect and manipulate objects during editing. More...

#include <EditorCamera.hpp>

Inheritance diagram for EditorCamera:
Camera

Public Member Functions

 EditorCamera ()
 Default constructor for the editor camera. Initializes camera parameters specific to the editor.
void Update (Engine::InputManager &input) override
 Updates the editor camera state. Handles movement, mouse rotation, and matrix updates using the input manager.
Public Member Functions inherited from Camera
 Camera ()
 Default camera constructor.
float ToRadians (float degree)
 Converts degrees to radians.
Maths::Mat4f Getprojection () const
 Returns the projection matrix.
Maths::Mat4f Getview () const
 Returns the view matrix.
Maths::Mat4f GetVP () const
 Returns the combined View-Projection matrix.

Additional Inherited Members

Protected Member Functions inherited from Camera
void RotationUpdate (Engine::InputManager &input)
 Updates the camera rotation based on mouse input.
void FowardUpdate ()
 Updates the forward vector based on the current camera rotation.
void RightUpdate ()
 Updates the right vector based on the camera orientation.
void UpUpdate ()
 Updates the up vector based on the camera orientation.
void ProjectionMatrix ()
 Calculates the projection matrix using perspective projection.
void ViewMatrix ()
 Calculates the view matrix transforming world space to camera space.
void VPMatrix ()
 Updates the View-Projection matrix.
void MouseUpdate (Engine::InputManager &input)
 Updates camera rotation using mouse movement.
void MoveUpdate (Engine::InputManager &input)
 Updates camera position based on keyboard input.
void GlobalUpdate (Engine::InputManager &input)
 Updates the global camera state including movement, rotation, and matrix calculations.
Protected Attributes inherited from Camera
Maths::Vec3f position
 Position of the camera in world space.
Maths::Quatf rotation
 Rotation of the camera represented as a quaternion.
Maths::Vec3f forward
 Forward direction vector of the camera.
Maths::Vec3f right
 Right direction vector of the camera.
Maths::Vec3f up
 Up direction vector of the camera.
float aspectRatio
 Aspect ratio of the camera viewport.
float nearPlane
 Near clipping plane distance.
float farPlane
 Far clipping plane distance.
float fov
 Field of view in degrees.
float moveSpeed = 0.5f
 Camera movement speed.
float sensitivity = 0.01f
 Mouse sensitivity used for camera rotation.
bool firstMousePos = true
 Indicates whether the first mouse position has been recorded.
Maths::Mat4f projection
 Projection matrix used for perspective transformation.
Maths::Mat4f view
 View matrix used to transform world coordinates into camera space.
Maths::Mat4f VP
 Combined View-Projection matrix (Projection * View).

Detailed Description

Camera used inside the editor environment. This camera allows free movement and rotation in the scene to inspect and manipulate objects during editing.

Constructor & Destructor Documentation

◆ EditorCamera()

EditorCamera::EditorCamera ( )

Default constructor for the editor camera. Initializes camera parameters specific to the editor.

Member Function Documentation

◆ Update()

void EditorCamera::Update ( Engine::InputManager & input)
overridevirtual

Updates the editor camera state. Handles movement, mouse rotation, and matrix updates using the input manager.

Parameters
inputInput manager used to control the camera

Implements Camera.


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