[skottie] Fix 3d rotation order

TBR=reed
Change-Id: I07263ad7ef0b86ce1ace19d68f3f3b08cfd76dfd
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/210300
Reviewed-by: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@chromium.org>
This commit is contained in:
Florin Malita 2019-04-24 19:39:46 -04:00 committed by Skia Commit-Bot
parent 46d0f9aad1
commit b783a43f0d
2 changed files with 3 additions and 3 deletions

View File

@ -90,13 +90,12 @@ SkMatrix44 TransformAdapter3D::totalMatrix() const {
t.setTranslate(-fAnchorPoint.fX, -fAnchorPoint.fY, -fAnchorPoint.fZ);
t.postScale(fScale.fX / 100, fScale.fY / 100, fScale.fZ / 100);
// TODO: SkMatrix44:postRotate()?
SkMatrix44 r;
r.setRotateDegreesAbout(1, 0, 0, fRotation.fX);
r.setRotateDegreesAbout(0, 0, 1, fRotation.fZ);
t.postConcat(r);
r.setRotateDegreesAbout(0, 1, 0, fRotation.fY);
t.postConcat(r);
r.setRotateDegreesAbout(0, 0, 1, fRotation.fZ);
r.setRotateDegreesAbout(1, 0, 0, fRotation.fX);
t.postConcat(r);
t.postTranslate(fPosition.fX, fPosition.fY, fPosition.fZ);

File diff suppressed because one or more lines are too long