mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[libgdx] Javadoc.
This commit is contained in:
parent
bfbc7567a5
commit
2d22a8f6f7
@ -1702,7 +1702,7 @@ public class Animation {
|
||||
}
|
||||
}
|
||||
|
||||
/** Changes {@link Skeleton#drawOrder}. */
|
||||
/** Changes the {@link Skeleton#getDrawOrder()}. */
|
||||
static public class DrawOrderTimeline extends Timeline {
|
||||
static final long propertyID = Property.drawOrder.ordinal();
|
||||
static private final long[] propertyIds = {propertyID};
|
||||
@ -1752,7 +1752,7 @@ public class Animation {
|
||||
}
|
||||
}
|
||||
|
||||
/** Changes a subset of {@link Skeleton#drawOrder}. */
|
||||
/** Changes a subset of the {@link Skeleton#getDrawOrder() draw order}. */
|
||||
static public class DrawOrderFolderTimeline extends Timeline {
|
||||
private final int[] slots;
|
||||
private final boolean[] inFolder;
|
||||
|
||||
@ -37,9 +37,9 @@ import com.badlogic.gdx.utils.Null;
|
||||
* <ul>
|
||||
* <li>{@link #data}: The setup pose.
|
||||
* <li>{@link #pose}: The unconstrained local pose. Set by animations and application code.
|
||||
* <li>{@link #appliedPose}: The constrained local pose. The {@link #pose} with modifications by constraints.
|
||||
* <li>World transform (on the applied pose): the {@link #appliedPose} combined with the parent world transform. Computed by
|
||||
* {@link Skeleton#updateWorldTransform(Physics)} and {@link BonePose#updateWorldTransform(Skeleton)}.
|
||||
* <li>{@link #appliedPose}: The local pose to use for rendering. Possibly modified by constraints.
|
||||
* <li>World transform: the local pose combined with the parent world transform. Computed on a pose by
|
||||
* {@link BonePose#updateWorldTransform(Skeleton)} and {@link Skeleton#updateWorldTransform(Physics)}.
|
||||
* </ul>
|
||||
*/
|
||||
public class Bone extends PosedActive<BoneData, BonePose> {
|
||||
|
||||
@ -29,7 +29,7 @@
|
||||
|
||||
package com.esotericsoftware.spine;
|
||||
|
||||
/** Stores the current pose for an IK constraint. */
|
||||
/** Stores a pose for an IK constraint. */
|
||||
public class IkConstraintPose implements Pose<IkConstraintPose> {
|
||||
int bendDirection;
|
||||
boolean compress, stretch;
|
||||
|
||||
@ -6,7 +6,7 @@ public enum Physics {
|
||||
/** Physics are not updated or applied. */
|
||||
none,
|
||||
|
||||
/** Physics are reset to the current pose. */
|
||||
/** Physics are {@link PhysicsConstraint#reset() reset}. */
|
||||
reset,
|
||||
|
||||
/** Physics are updated and the pose from physics is applied. */
|
||||
|
||||
@ -5,7 +5,7 @@ package com.esotericsoftware.spine;
|
||||
* <ul>
|
||||
* <li>{@link #data}: The setup pose.
|
||||
* <li>{@link #pose}: The unconstrained pose. Set by animations and application code.
|
||||
* <li>{@link #appliedPose}: The constrained pose. The {@link #pose} with modifications by constraints.
|
||||
* <li>{@link #appliedPose}: The pose to use for rendering. Possibly modified by constraints.
|
||||
* </ul>
|
||||
*/
|
||||
abstract public class Posed< //
|
||||
@ -13,8 +13,7 @@ abstract public class Posed< //
|
||||
P extends Pose> {
|
||||
|
||||
final D data;
|
||||
final P pose;
|
||||
final P constrainedPose;
|
||||
final P pose, constrainedPose;
|
||||
P appliedPose;
|
||||
|
||||
protected Posed (D data, P pose, P constrainedPose) {
|
||||
@ -40,19 +39,19 @@ abstract public class Posed< //
|
||||
return pose;
|
||||
}
|
||||
|
||||
/** If no constraints modify this object, the applied pose is the same as the {@link #pose}. Otherwise it is a copy of the
|
||||
* {@link #pose} modified by constraints. */
|
||||
/** The pose to use for rendering. If no constraints modify this pose, this is the same as {@link #pose}. Otherwise it is a
|
||||
* copy of {@link #pose} modified by constraints. */
|
||||
public P getAppliedPose () {
|
||||
return appliedPose;
|
||||
}
|
||||
|
||||
/** Sets the applied pose to the unconstrained pose, for when no constraints will modify the pose. */
|
||||
void pose () { // Port: usePose
|
||||
void pose () {
|
||||
appliedPose = pose;
|
||||
}
|
||||
|
||||
/** Sets the applied pose to the constrained pose, in anticipation of the applied pose being modified by constraints. */
|
||||
void constrained () { // Port: useConstrained
|
||||
void constrained () {
|
||||
appliedPose = constrainedPose;
|
||||
}
|
||||
|
||||
|
||||
@ -43,7 +43,10 @@ import com.esotericsoftware.spine.attachments.MeshAttachment;
|
||||
import com.esotericsoftware.spine.attachments.RegionAttachment;
|
||||
import com.esotericsoftware.spine.utils.SkeletonClipping;
|
||||
|
||||
/** Stores the current pose for a skeleton.
|
||||
/** Stores bones and slots to be posed by animations and application code. Multiple skeleton instances can share the same
|
||||
* {@link SkeletonData}, including animations, attachments, and skins.
|
||||
* <p>
|
||||
* After posing, call {@link #updateWorldTransform(Physics)} to apply constraints and compute world transforms for rendering.
|
||||
* <p>
|
||||
* See <a href="https://esotericsoftware.com/spine-runtime-architecture#Instance-objects">Instance objects</a> in the Spine
|
||||
* Runtimes Guide. */
|
||||
@ -463,7 +466,7 @@ public class Skeleton {
|
||||
return null;
|
||||
}
|
||||
|
||||
/** Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the current pose.
|
||||
/** Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the applied pose.
|
||||
* @param offset An output value, the distance from the skeleton origin to the bottom left corner of the AABB.
|
||||
* @param size An output value, the width and height of the AABB.
|
||||
* @param temp Working memory to temporarily store attachments' computed world vertices. */
|
||||
@ -471,7 +474,7 @@ public class Skeleton {
|
||||
getBounds(offset, size, temp, null);
|
||||
}
|
||||
|
||||
/** Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the current pose. Optionally applies
|
||||
/** Returns the axis aligned bounding box (AABB) of the region and mesh attachments for the applied pose. Optionally applies
|
||||
* clipping.
|
||||
* @param offset An output value, the distance from the skeleton origin to the bottom left corner of the AABB.
|
||||
* @param size An output value, the width and height of the AABB.
|
||||
|
||||
@ -37,7 +37,7 @@ import com.badlogic.gdx.utils.OrderedSet;
|
||||
import com.esotericsoftware.spine.attachments.Attachment;
|
||||
import com.esotericsoftware.spine.attachments.MeshAttachment;
|
||||
|
||||
/** Stores attachments by slot index and placeholder name.
|
||||
/** Stores attachments by slot index and placeholder name. Multiple {@link Skeleton} instances can use the same skins.
|
||||
* <p>
|
||||
* See {@link SkeletonData#defaultSkin}, {@link Skeleton#skin}, and
|
||||
* <a href="https://esotericsoftware.com/spine-runtime-skins">Runtime skins</a> in the Spine Runtimes Guide. */
|
||||
|
||||
@ -31,7 +31,9 @@ package com.esotericsoftware.spine.attachments;
|
||||
|
||||
import com.badlogic.gdx.utils.Null;
|
||||
|
||||
/** The base class for all attachments. */
|
||||
import com.esotericsoftware.spine.Skeleton;
|
||||
|
||||
/** The base class for all attachments. Multiple {@link Skeleton} instances, slots, or skins can use the same attachments. */
|
||||
abstract public class Attachment {
|
||||
final String name;
|
||||
@Null Attachment timelineAttachment;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user