[−][src]Struct storm::Sprite
Configuration settings for a sprite.
Fields
pos: Vector3<f32>
Position of the sprite. The X and Y coordinates represent the bottom left corner of the sprite. The Z coordinate represents sprite depth. Units are measured in pixels.
size: Vector2<u16>
Units are measured in pixels.
texture: Texture
Texture to apply to the sprite. The default is a plain white texture.
color: RGBA8
Color multiplier to apply to the sprite. The default is white.
rotation: u16
Rotation of the sprite. Units are 1/65536th of a turn.
Methods
impl Sprite
[src]
pub fn new(
pos: Vector3<f32>,
size: Vector2<f32>,
texture: Texture,
color: RGBA8,
rotation: f32
) -> Sprite
[src]
pos: Vector3<f32>,
size: Vector2<f32>,
texture: Texture,
color: RGBA8,
rotation: f32
) -> Sprite
Trait Implementations
impl Copy for Sprite
[src]
impl Default for Sprite
[src]
impl Clone for Sprite
[src]
fn clone(&self) -> Sprite
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Sprite
[src]
Auto Trait Implementations
impl Send for Sprite
impl Unpin for Sprite
impl Sync for Sprite
impl UnwindSafe for Sprite
impl RefUnwindSafe for Sprite
Blanket Implementations
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> SetParameter for T
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
T: Parameter<Self>,
Sets value
as a parameter of self
.