Inheritance: EventDispatcher → Node →
This node implements the vertex transformation shader logic which is required for skinning/skeletal animation.
Constructs a new skinning node.
skinnedMesh
The skinned mesh.
The bind matrix inverse node.
The bind matrix node.
The bind matrices as a uniform buffer node.
The current vertex position in local space.
The previous bind matrices as a uniform buffer node. Required for computing motion vectors.
Default is null.
The skin index attribute.
The skin weight attribute.
The skinned mesh.
The result of vertex position in local space.
The update type overwritten since skinning nodes are updated per object.
Overrides: Node#updateType
Generates the code snippet of the skinning node.
builder
The current node builder.
output
The current output.
Overrides: Node#generate
Returns: The generated code snippet.
Computes the transformed/skinned vertex position of the previous frame.
builder
The current node builder.
Returns: The skinned position from the previous frame.
Transforms the given vertex normal and tangent via skinning.
boneMatrices
The bone matrices
Default is this.boneMatricesNode.
normal
The vertex normal in local space.
Default is normalLocal.
tangent
The vertex tangent in local space.
Default is tangentLocal.
Returns: The transformed vertex normal and tangent.
Transforms the given vertex position via skinning.
boneMatrices
The bone matrices
Default is this.boneMatricesNode.
position
The vertex position in local space.
Default is this.positionNode.
Returns: The transformed vertex position.
Setups the skinning node by assigning the transformed vertex data to predefined node variables.
builder
The current node builder.
Overrides: Node#setup
Returns: The transformed vertex position.
Updates the state of the skinned mesh by updating the skeleton once per frame.
frame
The current node frame.
Overrides: Node#update