From 14f7b47f2c2315d0de5e52d31c57fe07a15d08ad Mon Sep 17 00:00:00 2001 From: Julian T Date: Fri, 12 Feb 2021 23:33:50 +0100 Subject: Implement multithreaded compiling of tiles --- src/world/mod.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/world') diff --git a/src/world/mod.rs b/src/world/mod.rs index ef239db..f0ba8d2 100644 --- a/src/world/mod.rs +++ b/src/world/mod.rs @@ -4,17 +4,17 @@ pub mod shapes; mod scene; pub use scene::*; -use std::rc::Rc; +use std::sync::Arc; use crate::core::Hittable; use crate::material::Material; pub struct Object { - pub shape: Box, - pub mat: Rc, + pub shape: Box, + pub mat: Arc, } impl Object { - pub fn new(mat: Rc, shape: Box) -> Self { + pub fn new(mat: Arc, shape: Box) -> Self { Object { mat, shape, -- cgit v1.2.3