Skip to content
Shapemetry

@huukhanhnguyen/model / validate/animations

validate/animations

animationTrackErrors()

animationTrackErrors(json, trackMethods): RegistryError[]

Structural track / bone-track-reference rules for animations[] + skeleton nodes in objects[]. Literal-only checks where possible (expression-driven values fail soft at eval).

Parameters

json

ModelJSON

trackMethods

Map<string, string>

Returns

RegistryError[]


trackMethodsOf()

trackMethodsOf(json): Map<string, string>

Every track key declared anywhere in animations[] → the METHOD that declared it — GLOBALLY, not scoped to one chain. Consumer-holds-the- reference (2026-08-14): a joint's *Track arg or a parameter's animation field names a track by key from anywhere in the model, with no notion of "which clip" to scope the lookup to — see @huukhanhnguyen/types evaluate/animation.ts's header. The method comes along because it states how many numbers one keyframe carries (vectorTrack = 3, quaternionTrack = 4, …) and a method name is never an expression — so a consumer's required shape is checkable here, before anything evaluates.

Parameters

json

ModelJSON

Returns

Map<string, string>

Last updated: 📖 1 min readEdit on GitHub