pub enum ProjectionMethod {
Orthographic {
size: f32,
},
Perspective {
fov: f32,
},
Physical {
focal_length: f32,
sensor_size: Vector2F32,
screen_fitting: PhysicalScreenFitting,
lens_shift: Vector2F32,
},
UI {
design_width: f32,
design_height: f32,
},
}Expand description
How the camera will project vertices?
Variants§
Orthographic
The orthographic projection
Perspective
The perspective projection. requires fov(unit: radians)
Physical
The perspective projection but computed from physically-based units(millimeters).
UI
UI layouting optimized projection: (0, 0)-(design_width, design_height) will be mapped to (-1, -1)-(1, 1) This projection ignores aspect ratio.
Trait Implementations§
Source§impl Clone for ProjectionMethod
impl Clone for ProjectionMethod
Source§fn clone(&self) -> ProjectionMethod
fn clone(&self) -> ProjectionMethod
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 ProjectionMethod
impl RefUnwindSafe for ProjectionMethod
impl Send for ProjectionMethod
impl Sync for ProjectionMethod
impl Unpin for ProjectionMethod
impl UnwindSafe for ProjectionMethod
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