Lloyd18
Lloyd18

Reputation: 1682

How to get skew values from displayObject transform?

There is no straight methods to get skew values in DisplayObject. Please, help me to get skewX and skewY values from transformation matrix of DisplayObject - I am forgot all the linear algebra stuff...

Will be grateful for any help.

Upvotes: 2

Views: 971

Answers (1)

p.balmasov
p.balmasov

Reputation: 357

    var matrix:Matrix = target.transform.matrix;
    var yAngle:Number = matrix.b / Math.PI * 180;
    var xAngle:Number = matrix.c / Math.PI * 180;

xAngle and yAngle - skew in degrees

next time read reference to Matrix class

Upvotes: 1

Related Questions