Theme:

SkinnedMesh

A mesh with skeletal animation support. Requires a Skeleton and skinIndex/skinWeight buffer attributes in the geometry.

Extends Mesh.

Typically created by loaders (e.g. GLTFLoader) rather than manually.

Constructor

const mesh = new SkinnedMesh(geometry?, material?)

Properties

  • isSkinnedMesh — Type flag (true)
  • bindMatrix — Matrix4, base transform for bone binding
  • bindMatrixInverse — Matrix4, inverse of bind matrix
  • boundingBox — Box3 or null (compute manually via computeBoundingBox())
  • boundingSphere — Sphere or null (computed on demand)
  • skeleton — The bound Skeleton (set via bind())

Methods

  • bind(skeleton, bindMatrix?) — Bind a skeleton. If no bindMatrix, uses current world matrix.
  • pose() — Reset to rest pose
  • normalizeSkinWeights() — Normalize skin weights so they sum to 1
  • computeBoundingBox() — Compute AABB accounting for skinning
  • computeBoundingSphere() — Compute bounding sphere accounting for skinning
  • applyBoneTransform(index, target) — Apply bone transform to a vertex position
  • getVertexPosition(index, target) — Get skinned vertex position
  • raycast(raycaster, intersects) — Ray intersection (uses skinned bounding volumes)
  • copy(source, recursive?) — Copy skinned mesh data