Skip to content
Snippets Groups Projects
Commit 758c1e74 authored by Sebastian Gaida's avatar Sebastian Gaida
Browse files

[#35] remove setFront and setPosition functions

removed due to not used and problems with them before
parent d54f0064
No related branches found
No related tags found
1 merge request!26Resolve "Kamera - Erstellung und Handling"
Pipeline #25146 passed
......@@ -56,13 +56,10 @@ namespace vkcv {
glm::vec3 getFront();
void setFront( glm::vec3 front );
glm::vec3 getPosition();
void setPosition( glm::vec3 position );
void movePosition( glm::vec3 translation );
};
......
......@@ -79,10 +79,6 @@ namespace vkcv {
return glm::vec3( m_view[2].x,m_view[2].y,-m_view[2].z);
}
void Camera::setFront( glm::vec3 front ){
m_view[2] = glm::vec4(front, m_view[2][3]);
}
glm::vec3 Camera::getPosition(){
glm::vec3 pos = glm::vec3( glm::column(m_view, 3));
glm::mat3 mat_inv = glm::inverse( glm::mat3(m_view));
......@@ -95,11 +91,4 @@ namespace vkcv {
translation[3] = glm::vec4(-position, 1.0f);
m_view = m_view * translation;
}
void Camera::movePosition( glm::vec3 translation ){
glm::vec3 pos = getPosition();
pos += translation;
setPosition(pos);
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment