refactor: scene deserialization organisation

This commit is contained in:
2026-05-02 18:02:53 +02:00
parent a44e61c1f7
commit eb90c36ae8
8 changed files with 160 additions and 172 deletions

View File

@@ -11,7 +11,6 @@ use super::hit::Hit;
#[derive(Debug)]
pub struct Cube {
faces: Vec<Arc<dyn Hittable>>,
material: Arc<dyn Material>,
}
impl Cube {
@@ -34,7 +33,7 @@ impl Cube {
Arc::new(Quad::new(p5, p6, p7, p8, material.clone())),
Arc::new(Quad::new(p4, p3, p7, p8, material.clone())),
];
Self { faces, material }
Self { faces }
}
}