From c695da871a75bb6786c08c3546ef71ed032bd61d Mon Sep 17 00:00:00 2001 From: Julian T Date: Sat, 13 Feb 2021 19:58:54 +0100 Subject: Fixed test and compile warnings --- src/camera/camera.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/camera/camera.rs') diff --git a/src/camera/camera.rs b/src/camera/camera.rs index 241d26b..7f9e79d 100644 --- a/src/camera/camera.rs +++ b/src/camera/camera.rs @@ -8,6 +8,7 @@ //! ``` //! use rendering::camera::{CameraSettings, Camera}; //! use rendering::core::{Vector3f, Vector2f, Vector2i}; +//! use rendering::sample::UniformSampler; //! //! let set = CameraSettings { //! origin: Vector3f::new(10.0), @@ -16,12 +17,13 @@ //! fov: 90.0, //! filmsize: Vector2i::new(10), //! focus: None, -//! aperture: 0.0, +//! aperture: None, //! }; //! //! let cam = Camera::new(&set); +//! let mut sampler = UniformSampler::new(); //! -//! let (r, _) = cam.generate_ray(&Vector2f::new(5.0)); +//! let (r, _) = cam.generate_ray(&Vector2f::new(5.0), &mut sampler); //! let dir = r.direction; //! //! assert!( -- cgit v1.2.3