SkeletonResource
Represents a skeleton asset with joint hierarchy and animation capabilities.
Declaration
final class SkeletonResourceOverview
SkeletonResource is the single type for defining and using skeletons. It encapsulates the joint hierarchy together with additional animation-related skeletal data into one self-contained, immutable animation resource.
Basic Usage
Create a skeleton resource with joints and (optionally) animation-evaluation data:
typealias Joint = SkeletonResource.Joint
let skeleton = try SkeletonResource(
named: "Character",
rootJoint: try Joint("Root") {
try Joint("Spine")
},
animationEvaluation: .init(
ikResources: [ikResource1, ikResource2],
blendMasks: blendMasks
)
)Related Types
SkeletonResource.Joint - Represents a single joint in the skeleton hierarchy
SkeletonResource.AnimationEvaluation - Bundle of additional animation-related skeletal data
SkeletonResource.BlendMask - Defines selective weighting for joint animation control