Renderer · const
MAX_JOINTS
The most joints one palette can hold.
Explained in Hello world.
const MAX_JOINTS = 512import { MAX_JOINTS } from '@driftengine/core';In depth
WebGL2 guarantees MAX_TEXTURE_SIZE of 2048 and promises nothing above it, so a single-row
palette holds 2048 / 4 matrices. A humanoid rig is sixty to ninety joints, so this is not a
limit anybody meets by accident — but it is stated, refused at construction and named in the
error, because a limit a consumer discovers is a defect and a limit they read is a
specification.
What it costs is that a crowd cannot share one palette. What would make it wrong is a rig above it, and the fix is wrapping onto more rows — which costs one division in the vertex stage and is why it is not the starting point.