pub struct Transform {
pub xx: f32,
pub yx: f32,
pub xy: f32,
pub yy: f32,
pub dx: f32,
pub dy: f32,
}Fields§
§xx: f32§yx: f32§xy: f32§yy: f32§dx: f32§dy: f32Implementations§
Source§impl Transform
impl Transform
pub const IDENTITY: Self
pub const fn new(xx: f32, yx: f32, xy: f32, yy: f32, dx: f32, dy: f32) -> Self
pub const fn translation(x: f32, y: f32) -> Self
pub const fn translation_vector(delta: Vector) -> Self
pub const fn scale(x: f32, y: f32) -> Self
pub fn rotation(radians: f32) -> Self
pub const fn is_identity(self) -> bool
pub fn then(self, next: Self) -> Self
pub fn transform_point(self, point: Point) -> Point
pub fn transform_vector(self, vector: Vector) -> Vector
pub fn inverse(self) -> Option<Self>
pub fn transform_rect_bbox(self, rect: Rect) -> Rect
Trait Implementations§
impl Copy for Transform
impl StructuralPartialEq for Transform
Auto Trait Implementations§
impl Forget for Transform
impl Freeze for Transform
impl Move for Transform
impl RefUnwindSafe for Transform
impl Send for Transform
impl Sync for Transform
impl Unpin for Transform
impl UnsafeUnpin 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