diff options
author | Julian T <julian@jtle.dk> | 2021-01-29 00:58:32 +0100 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2021-01-29 00:58:32 +0100 |
commit | fdb3e8cb8d53449c107388e143345beae162f95e (patch) | |
tree | 7a04102eb2722d2fddeefd0b2e1fa0e8a4e995f3 /src/main.rs | |
parent | f467334b26f31b19ebbd222de2b4167b1538ccee (diff) |
Finish get_tile on Film
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs index e7a11a9..0ac71df 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,3 +1,16 @@ +use pathtrace::camera::filter::Filter; +use pathtrace::camera::film::Film; +use pathtrace::vector::{Vector2i, Vector2f}; +use pathtrace::bound::Bound2i; + +use std::rc::Rc; + fn main() { - println!("Hello, world!"); + + let filter = Rc::new(Filter::new_box(Vector2f::new(2.5))); + + let film = Film::new(Vector2i::new(100), filter.clone()); + let tile = film.get_tile(&Bound2i::new_xyxy(10, 10, 100, 100)); + + println!("Yo {}", tile.bounds.min.x); } |