pub struct BaseCamera {
pub camera_to_world: AnimatedTransform,
pub shutter_open: Float,
pub shutter_close: Float,
pub film: Arc<RwLock<Film>>,
pub medium: Option<Arc<dyn Medium>>,
}
Fields§
§camera_to_world: AnimatedTransform
§shutter_open: Float
§shutter_close: Float
§film: Arc<RwLock<Film>>
§medium: Option<Arc<dyn Medium>>
Implementations§
Source§impl BaseCamera
impl BaseCamera
pub fn new( camera_to_world: &AnimatedTransform, shutter_open: Float, shutter_close: Float, film: &Arc<RwLock<Film>>, medium: &Option<Arc<dyn Medium>>, ) -> Self
pub fn get_film(&self) -> Arc<RwLock<Film>>
pub fn get_medium(&self) -> Option<Arc<dyn Medium>>
pub fn get_shutter(&self) -> (Float, Float)
pub fn generate_ray_differential( camera: &dyn Camera, sample: &CameraSample, ) -> Option<(Float, RayDifferential)>
Trait Implementations§
Source§impl Clone for BaseCamera
impl Clone for BaseCamera
Source§fn clone(&self) -> BaseCamera
fn clone(&self) -> BaseCamera
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for BaseCamera
impl !RefUnwindSafe for BaseCamera
impl Send for BaseCamera
impl Sync for BaseCamera
impl Unpin for BaseCamera
impl !UnwindSafe for BaseCamera
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more