Struct ascending_graphics::System
source · pub struct System<Controls: Controls> {
pub screen_size: [f32; 2],
/* private fields */
}Fields§
§screen_size: [f32; 2]Implementations§
source§impl<Controls> System<Controls>where
Controls: Controls,
impl<Controls> System<Controls>where
Controls: Controls,
pub fn bind_group(&self) -> &BindGroup
pub fn controls(&self) -> &Controls
pub fn controls_mut(&mut self) -> &mut Controls
pub fn eye(&self) -> [f32; 3]
pub fn new( renderer: &mut GpuRenderer, projection: Projection, controls: Controls, screen_size: [f32; 2], manual_view: Mat4, manual_scale: f32 ) -> Self
pub fn projection(&self) -> Mat4
pub fn set_controls(&mut self, controls: Controls) -> Controls
pub fn set_projection(&mut self, projection: Projection)
pub fn set_manual_view(&mut self, view: Mat4, scale: f32)
pub fn manual_view(&self) -> Mat4
pub fn mut_manual_view(&mut self) -> &mut Mat4
pub fn manual_scale(&self) -> f32
pub fn mut_manual_scale(&mut self) -> &mut f32
pub fn update(&mut self, renderer: &GpuRenderer, frame_time: &FrameTime)
pub fn update_screen(&mut self, renderer: &GpuRenderer, screen_size: [f32; 2])
pub fn view(&self) -> Mat4
pub fn projected_world_to_screen( &self, camera_type: CameraType, bounds: &Bounds ) -> Vec4
pub fn world_to_screen(&self, camera_type: CameraType, bounds: &Bounds) -> Vec4
pub fn world_to_screen_direct( screen_size: [f32; 2], scale: f32, projection: Mat4, left: f32, bottom: f32, right: f32, top: f32 ) -> Vec4
Auto Trait Implementations§
impl<Controls> !Freeze for System<Controls>
impl<Controls> !RefUnwindSafe for System<Controls>
impl<Controls> Send for System<Controls>where
Controls: Send,
impl<Controls> Sync for System<Controls>where
Controls: Sync,
impl<Controls> Unpin for System<Controls>where
Controls: Unpin,
impl<Controls> !UnwindSafe for System<Controls>
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> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.source§impl<T> DowncastSync for T
impl<T> DowncastSync for T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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