diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/src/main.rs b/src/main.rs index bf70415..3a757db 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,18 +1,14 @@ -mod vector; mod camera; mod canvas; use std::f32::consts::PI; +use cgmath::Vector3; -use crate::{camera::{Buffer, Camera}, vector::Vector}; - -trait Object { - fn sdf(&self, point: Vector) -> f32; -} +use crate::camera::{Buffer, Camera}; fn main() { let mut cam = Camera { - position: Vector { x: 0.0, y: -0.7, z: 0.0 }, - direction: Vector { x: 1.0, y: 0.0, z: 0.0 }, + position: Vector3 { x: 0.0, y: -0.7, z: 0.0 }, + direction: Vector3 { x: 1.0, y: 0.0, z: 0.0 }, angle: PI / 2.0, distance: 1.0, aspect_ratio: 1.0, |