Schemas / Animation / modulators
rig.anim.curve
v1.0.0 · stable maturity: stable 4 fields 1 required
Fields
| Field | Type | Meaning | |
|---|---|---|---|
points |
array<vec2>min 2 items | required | Control points. Each x/y in [0,1]. Sorted by ascending x. At least two points; hosts ensure endpoints at x=0 and x=1. |
interpolation |
enumlinear · smooth · bezier | optional | Optional. linear, smooth, bezier; absent = smooth. |
handles |
array<object> | optional | Optional. Per-anchor {in, out} relative offsets. Same length as points. Meaningful only when interpolation is bezier; ignored otherwise. Hosts clamp each handle's x so the control point stays inside its segment (evaluation stays a function of t). |
preset |
enumlinear · ease-in · ease-out · ease-in-out · s-curve · bulge · squeeze · custom | optional | Optional. Named seed for points: linear, ease-in, ease-out, ease-in-out, s-curve, bulge, squeeze, custom. Absent = custom when points are authored, else linear. |
1D transfer curve - remap a normalized input t in [0,1] to an output in [0,1]. Format when present.
Used for easing, distribution, bulge/squeeze, and any host that needs an editable response curve. Not a 2D draw path - that is rig.geometry.path. Named tween easings on rig.anim.tween stay as the short enum; this schema is the editable shape those names seed.
Rules
- Evaluating at
tinterpolates inxand returnsy(clamped to[0,1]).bezieris a cubic segment between neighbouring anchors using that pair'sout/inhandles. - Changing
presetto a named seed regeneratespoints. Editing points setspresettocustom. - Runtime LUTs / caches are host-only - do not serialize.
- Treat unknown
interpolation/presetassmooth/custom(keep points).handleswithoutbezierare ignored.
JSON Schema
Resolves at https://rig.works/schemas/rig.anim.curve.schema.json —
raw file.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://rig.works/schemas/rig.anim.curve.schema.json",
"title": "rig.anim.curve",
"type": "object",
"additionalProperties": false,
"properties": {
"points": {
"type": "array",
"minItems": 2,
"items": {
"$ref": "./_defs.schema.json#/$defs/vec2"
}
},
"interpolation": {
"type": "string",
"enum": [
"linear",
"smooth",
"bezier"
]
},
"handles": {
"type": "array",
"items": {
"type": "object",
"additionalProperties": false,
"properties": {
"in": {
"$ref": "./_defs.schema.json#/$defs/vec2"
},
"out": {
"$ref": "./_defs.schema.json#/$defs/vec2"
}
}
}
},
"preset": {
"type": "string",
"enum": [
"linear",
"ease-in",
"ease-out",
"ease-in-out",
"s-curve",
"bulge",
"squeeze",
"custom"
]
}
},
"required": [
"points"
],
"x-rig-maturity": "stable"
}