World camera position and target

This commit is contained in:
Thomas Forgione 2019-06-24 09:48:52 +02:00
parent 3b1370ad0b
commit 0ecdf3dcc0
No known key found for this signature in database
GPG Key ID: 203DAEA747F48F41
1 changed files with 5 additions and 2 deletions

View File

@ -246,10 +246,13 @@ fn main() {
} => {
trace!("Camera:");
let world_position = camera.position * size_f64 + center_f64;
let world_target = camera.target * size_f64 + center_f64;
trace!("\tPosition: ({}, {}, {})",
camera.position.x(), camera.position.y(), camera.position.z());
world_position.x(), world_position.y(), world_position.z());
trace!("\tTarget: ({}, {}, {})",
camera.target.x(), camera.target.y(), camera.target.z());
world_target.x(), world_target.y(), world_target.z());
trace!("\tUp: ({}, {}, {})",
camera.up.x(), camera.up.y(), camera.up.z());
},