mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-16 03:51:37 +08:00
[c] New labeled goto convention.
This commit is contained in:
parent
5030ef5582
commit
947f055ab3
@ -160,7 +160,7 @@ void spIkConstraint_apply2 (spBone* parent, spBone* child, float targetX, float
|
||||
y = SQRT(dd - r * r) * bendDir;
|
||||
a1 = ta - ATAN2(y, r);
|
||||
a2 = ATAN2(y / psy, (r - l1) / psx);
|
||||
goto outer;
|
||||
goto break_outer;
|
||||
}
|
||||
}
|
||||
{
|
||||
@ -194,7 +194,7 @@ void spIkConstraint_apply2 (spBone* parent, spBone* child, float targetX, float
|
||||
}
|
||||
}
|
||||
}
|
||||
outer: {
|
||||
break_outer: {
|
||||
float os = ATAN2(cy, cx) * s2;
|
||||
a1 = (a1 - os) * RAD_DEG + o1 - parent->arotation;
|
||||
if (a1 > 180) a1 -= 360;
|
||||
|
||||
@ -351,14 +351,14 @@ void spSkeleton_updateCache (spSkeleton* self) {
|
||||
constraintCount = ikCount + transformCount + pathCount;
|
||||
|
||||
i = 0;
|
||||
outer:
|
||||
continue_outer:
|
||||
for (; i < constraintCount; i++) {
|
||||
for (ii = 0; ii < ikCount; ii++) {
|
||||
spIkConstraint* ikConstraint = ikConstraints[ii];
|
||||
if (ikConstraint->data->order == i) {
|
||||
_sortIkConstraint(internal, ikConstraint);
|
||||
i++;
|
||||
goto outer;
|
||||
goto continue_outer;
|
||||
}
|
||||
}
|
||||
|
||||
@ -367,7 +367,7 @@ void spSkeleton_updateCache (spSkeleton* self) {
|
||||
if (transformConstraint->data->order == i) {
|
||||
_sortTransformConstraint(internal, transformConstraint);
|
||||
i++;
|
||||
goto outer;
|
||||
goto continue_outer;
|
||||
}
|
||||
}
|
||||
|
||||
@ -376,7 +376,7 @@ void spSkeleton_updateCache (spSkeleton* self) {
|
||||
if (pathConstraint->data->order == i) {
|
||||
_sortPathConstraint(internal, pathConstraint);
|
||||
i++;
|
||||
goto outer;
|
||||
goto continue_outer;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -220,7 +220,7 @@ void spSkeletonClipping_clipTriangles(spSkeletonClipping* self, float* vertices,
|
||||
spFloatArray_clear(clippedUVs);
|
||||
spUnsignedShortArray_clear(clippedTriangles);
|
||||
i = 0;
|
||||
outer:
|
||||
continue_outer:
|
||||
for (; i < trianglesLength; i += 3) {
|
||||
int p;
|
||||
int vertexOffset = triangles[i] * stride;
|
||||
@ -306,7 +306,7 @@ void spSkeletonClipping_clipTriangles(spSkeletonClipping* self, float* vertices,
|
||||
clippedTrianglesItems[s + 2] = (unsigned short)(index + 2);
|
||||
index += 3;
|
||||
i += 3;
|
||||
goto outer;
|
||||
goto continue_outer;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -168,13 +168,13 @@ spShortArray* spTriangulator_triangulate(spTriangulator* self, spFloatArray* ver
|
||||
vx = vertices[v]; vy = vertices[v + 1];
|
||||
if (_positiveArea(p3x, p3y, p1x, p1y, vx, vy)) {
|
||||
if (_positiveArea(p1x, p1y, p2x, p2y, vx, vy)) {
|
||||
if (_positiveArea(p2x, p2y, p3x, p3y, vx, vy)) goto outer;
|
||||
if (_positiveArea(p2x, p2y, p3x, p3y, vx, vy)) goto break_outer;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
outer:
|
||||
break_outer:
|
||||
|
||||
if (next == 0) {
|
||||
do {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user