mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
Fixed local rotation when inherit rotation is disabled.
This commit is contained in:
parent
2e87ab8f9f
commit
3bfe462534
@ -166,23 +166,16 @@ public class Bone implements Updatable {
|
|||||||
pb = cosDeg(prx + 90) * psy;
|
pb = cosDeg(prx + 90) * psy;
|
||||||
pc = sinDeg(prx) * psx;
|
pc = sinDeg(prx) * psx;
|
||||||
pd = sinDeg(prx + 90) * psy;
|
pd = sinDeg(prx + 90) * psy;
|
||||||
float rotationY = rotation + 90 + shearY;
|
float rx = rotation + shearX - prx;
|
||||||
float la = cosDeg(rotation + shearX) * scaleX;
|
float ry = rotation + shearY - prx + 90;
|
||||||
float lb = cosDeg(rotationY) * scaleY;
|
float la = cosDeg(rx) * scaleX;
|
||||||
float lc = sinDeg(rotation + shearX) * scaleX;
|
float lb = cosDeg(ry) * scaleY;
|
||||||
float ld = sinDeg(rotationY) * scaleY;
|
float lc = sinDeg(rx) * scaleX;
|
||||||
float za = pa * la + pb * lc;
|
float ld = sinDeg(ry) * scaleY;
|
||||||
float zb = pa * lb + pb * ld;
|
a = pa * la + pb * lc;
|
||||||
float zc = pc * la + pd * lc;
|
b = pa * lb + pb * ld;
|
||||||
float zd = pc * lb + pd * ld;
|
c = pc * la + pd * lc;
|
||||||
pa = cosDeg(-prx);
|
d = pc * lb + pd * ld;
|
||||||
pb = cosDeg(90 - prx);
|
|
||||||
pc = sinDeg(-prx);
|
|
||||||
pd = sinDeg(90 - prx);
|
|
||||||
a = za * pa + zb * pc;
|
|
||||||
b = za * pb + zb * pd;
|
|
||||||
c = zc * pa + zd * pc;
|
|
||||||
d = zc * pb + zd * pd;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case noScale:
|
case noScale:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user