pub struct Transform {
pub pivot: Vec2,
pub align: Vec2,
pub translation: Vec2,
pub rotation: f32,
pub scale: Vec2,
pub skew: Vec2,
}
Fields§
§pivot: Vec2
Rectangle center of mass. Values in range: <0;1>
align: Vec2
Translation in rectangle fraction units. Values in range: <0;1>
translation: Vec2
Translation in regular units.
rotation: f32
Rotation in radian angle units.
scale: Vec2
Scale in regular units.
skew: Vec2
Skewing in radian angle units. {angle X, angle Y}
Trait Implementations§
source§impl<'de> Deserialize<'de> for Transform
impl<'de> Deserialize<'de> for Transform
source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<Transform, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<Transform, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Prefab for Transform
impl Prefab for Transform
fn from_prefab(data: Value) -> Result<Self, PrefabError>
fn to_prefab(&self) -> Result<Value, PrefabError>
source§impl Serialize for Transform
impl Serialize for Transform
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 Transform
impl StructuralPartialEq for Transform
Auto Trait Implementations§
impl Freeze for Transform
impl RefUnwindSafe for Transform
impl Send for Transform
impl Sync for Transform
impl Unpin for Transform
impl UnwindSafe for Transform
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)