pub struct Sprite {
pub name: String,
pub source: String,
pub offset: [i32; 2],
pub width: i32,
pub height: i32,
pub unknown: i32,
pub uv: [f32; 4],
}Expand description
A sprite of a sprite sheet.
Fields§
§name: StringThe sprite’s name.
source: StringThe image file it came from.
offset: [i32; 2]Offset of the trimmed image inside the original source image.
width: i32The width in pixels.
height: i32The height in pixels.
unknown: i32Not identified yet.
uv: [f32; 4]u0, v0, u1, v1 in the sheet image.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Sprite
impl RefUnwindSafe for Sprite
impl Send for Sprite
impl Sync for Sprite
impl Unpin for Sprite
impl UnsafeUnpin for Sprite
impl UnwindSafe for Sprite
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