diff options
author | Julian T <julian@jtle.dk> | 2021-02-10 23:06:48 +0100 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2021-02-10 23:06:48 +0100 |
commit | 49c6adb0db70ffc30eaac33b66eacf7574b34e26 (patch) | |
tree | 60f828ce8abf962fe2d88fdeb4e04db1d7663253 /src/main.rs | |
parent | 3a144c8c1fc83150fc06d792082db5cc4bce3cc5 (diff) |
Fixed most clippy warnings
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs index 2247834..215e0d4 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,7 +1,6 @@ use rendering::camera::{Camera, Film, CameraSettings}; -use rendering::scene::{Scene, Object}; +use rendering::world::{Scene, Object, shapes::Sphere}; use rendering::trace::DefaultTracer; -use rendering::scene::shapes::Sphere; use rendering::core::{Vector2i, Vector3f, Spectrum}; use rendering::render::{RenderContext, RenderCoord}; use rendering::sample::UniformSampler; @@ -28,9 +27,9 @@ fn main() { let mut scn = Scene::new(); scn.add_objects(vec![ - Object::new(metal.clone(), Box::new(Sphere::new(0.5, Vector3f::new_xyz(0.0, 0.0, -1.0)))), - Object::new(blue.clone(), Box::new(Sphere::new(0.5, Vector3f::new_xyz(1.0, 0.0, -1.0)))), - Object::new(brown.clone(), Box::new(Sphere::new(100.0, Vector3f::new_xyz(0.0, -100.5, -1.0)))), + Object::new(metal, Box::new(Sphere::new(0.5, Vector3f::new_xyz(0.0, 0.0, -1.0)))), + Object::new(blue, Box::new(Sphere::new(0.5, Vector3f::new_xyz(1.0, 0.0, -1.0)))), + Object::new(brown, Box::new(Sphere::new(100.0, Vector3f::new_xyz(0.0, -100.5, -1.0)))), ]); let tracer = DefaultTracer::new(&scn, Some(50)); |