From 6fbb47c9b82a532267fd912527b9d44b3f28826e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20du=20Garreau?= Date: Mon, 21 Mar 2022 09:00:54 +0100 Subject: [PATCH] Use `Vec3::ZERO` --- wgpu/examples/cube/main.rs | 2 +- wgpu/examples/water/main.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wgpu/examples/cube/main.rs b/wgpu/examples/cube/main.rs index 29a1c9fd66..b1d8c48931 100644 --- a/wgpu/examples/cube/main.rs +++ b/wgpu/examples/cube/main.rs @@ -115,7 +115,7 @@ impl Example { let projection = glam::Mat4::perspective_rh(consts::FRAC_PI_4, aspect_ratio, 1.0, 10.0); let view = glam::Mat4::look_at_rh( glam::Vec3::new(1.5f32, -5.0, 3.0), - glam::Vec3::new(0f32, 0.0, 0.0), + glam::Vec3::ZERO, glam::Vec3::Z, ); projection * view diff --git a/wgpu/examples/water/main.rs b/wgpu/examples/water/main.rs index cf18aa7f55..7ff7c7e465 100644 --- a/wgpu/examples/water/main.rs +++ b/wgpu/examples/water/main.rs @@ -108,7 +108,7 @@ impl Example { let flipped_view = glam::Mat4::look_at_rh( glam::Vec3::new(CAMERA.x, -CAMERA.y, CAMERA.z), - glam::Vec3::new(0f32, 0.0, 0.0), + glam::Vec3::ZERO, glam::Vec3::Y, );