Struct piston_window::prelude::RenderArgs
source · pub struct RenderArgs {
pub ext_dt: f64,
pub window_size: [f64; 2],
pub draw_size: [u32; 2],
}
Expand description
Render arguments.
Fields§
§ext_dt: f64
Extrapolated time in seconds, used to do smooth animation.
window_size: [f64; 2]
The width and height of rendered area in points.
draw_size: [u32; 2]
The width and height of rendered area in pixels.
Implementations§
Trait Implementations§
source§impl Clone for RenderArgs
impl Clone for RenderArgs
source§fn clone(&self) -> RenderArgs
fn clone(&self) -> RenderArgs
Returns a copy 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 moresource§impl Debug for RenderArgs
impl Debug for RenderArgs
source§impl<'de> Deserialize<'de> for RenderArgs
impl<'de> Deserialize<'de> for RenderArgs
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<RenderArgs, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<RenderArgs, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl From<RenderArgs> for Event
impl From<RenderArgs> for Event
source§fn from(args: RenderArgs) -> Event
fn from(args: RenderArgs) -> Event
Converts to this type from the input type.
source§impl From<RenderArgs> for Loop
impl From<RenderArgs> for Loop
source§fn from(args: RenderArgs) -> Loop
fn from(args: RenderArgs) -> Loop
Converts to this type from the input type.
source§impl PartialEq for RenderArgs
impl PartialEq for RenderArgs
source§fn eq(&self, other: &RenderArgs) -> bool
fn eq(&self, other: &RenderArgs) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for RenderArgs
impl PartialOrd for RenderArgs
source§fn partial_cmp(&self, other: &RenderArgs) -> Option<Ordering>
fn partial_cmp(&self, other: &RenderArgs) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moresource§impl Serialize for RenderArgs
impl Serialize for RenderArgs
source§fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Copy for RenderArgs
impl StructuralPartialEq for RenderArgs
Auto Trait Implementations§
impl Freeze for RenderArgs
impl RefUnwindSafe for RenderArgs
impl Send for RenderArgs
impl Sync for RenderArgs
impl Unpin for RenderArgs
impl UnwindSafe for RenderArgs
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