camera refactor
This commit is contained in:
@@ -39,9 +39,8 @@ void Camera::update(Pad &t_pad, Mesh &t_mesh)
|
||||
{
|
||||
rotate(t_pad);
|
||||
followBy(t_mesh);
|
||||
updatePlanes(t_mesh.position); // TODO move it out
|
||||
Vector3 newPos = Vector3(t_mesh.position.x, t_mesh.position.y + 10.0F, t_mesh.position.z);
|
||||
worldView.lookAt(up, position, newPos);
|
||||
Vector3 lookPos = Vector3(t_mesh.position.x, t_mesh.position.y + 10.0F, t_mesh.position.z);
|
||||
lookAt(lookPos);
|
||||
}
|
||||
|
||||
/** Set camera rotation by pad right joy and update unit circle
|
||||
|
||||
@@ -39,8 +39,7 @@ void Camera::update(Pad &t_pad, Mesh &t_mesh)
|
||||
{
|
||||
rotate(t_pad);
|
||||
followBy(t_mesh);
|
||||
updatePlanes(t_mesh.position);
|
||||
worldView.lookAt(up, position, t_mesh.position);
|
||||
lookAt(t_mesh.position);
|
||||
}
|
||||
|
||||
/** Set camera rotation by pad right joy and update unit circle
|
||||
|
||||
Reference in New Issue
Block a user