use crate::transform::Transform; use crate::vector::Vec3; #[derive(Debug)] pub struct Camera { transform: Transform, } impl Camera { pub fn translate(&mut self, translation: Vec3) { self.transform.set_translation(translation); } pub(crate) fn new() -> Self { let mut transform = Transform::new(); transform.set_translation(Vec3 { x: 0.0, y: 0.0, z: -3.0, }); Self { transform } } pub(crate) fn transform(&self) -> &Transform { &self.transform } }