This commit is contained in:
Robert 2021-01-23 16:43:59 +01:00
parent a17c73d3c9
commit d74c49fed5
6 changed files with 34 additions and 19 deletions

View file

@ -78,6 +78,16 @@ namespace oglu
*/
void LookAt(const GLfloat* target);
/**
* @brief Have camera face at a certain position.
*
* This will adjust the camera's rotation in order to put the
* specified coordinate at the center of the screen.
*
* @param[in] target 3D vector with the target position
*/
void LookAt(const glm::vec3& target);
/**
* @brief Have camera face at a certain position.
*
@ -88,8 +98,6 @@ namespace oglu
*/
void LookAt(const Transformable& target);
// void Move(float x, float y, float z) override;
/**
* @brief Gets the projection matrix of the camera.
*

View file

@ -307,28 +307,28 @@ namespace oglu
*
* @return An array of 16 floats representing the transformation matrix
*/
const float* GetMatrix();
virtual const glm::mat4& GetMatrix();
/**
* @brief Get position as a 3D vector.
*
* @returns A pointer to an array of floats
*/
const float* GetPosition() const;
virtual const glm::vec3& GetPosition() const;
/**
* @brief Get rotation as a matrix.
*
* @returns A pointer to a 4x4 matrix
*/
const float* GetRotation() const;
virtual const glm::quat& GetRotation() const;
/**
* @brief Get scaling as a 3D vector.
*
* @returns A pointer to an array of floats
*/
const float* GetScaling() const;
virtual const glm::vec3& GetScaling() const;
protected:
// TODO: Separate translation, rotation and scaling matrices.