Schemas / Music
rig.music.transport
v0.31.0 · draft 8 fields 1 required
Fields
| Field | Type | Meaning | |
|---|---|---|---|
playing |
bool | optional | Optional. Running; absent = false |
bpm |
float | required | Tempo |
timeSigNum |
int | optional | Optional. Beats per bar; absent = 4 |
timeSigDen |
int | optional | Optional. Note value of beat; absent = 4 |
positionBeats |
float | optional | Optional. Playhead in beats; absent = 0 |
loop |
bool | optional | Optional. Loop; absent = false |
loopStartBeats |
float | optional | Loop in; required when loop |
loopEndBeats |
float | optional | Loop out; required when loop |
Tempo and playhead authority. One per scene when music schemas are present.
barIndex / beatInBar are derived from positionBeats - do not serialize; recompute.
Pause = playing=false while keeping positionBeats.
Advance during Update. Clock / pattern / sequencer do not own bpm or the global playhead.
JSON Schema
Resolves at https://rig.works/schemas/rig.music.transport.schema.json —
raw file.
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "https://rig.works/schemas/rig.music.transport.schema.json",
"title": "rig.music.transport",
"type": "object",
"additionalProperties": false,
"properties": {
"playing": {
"$ref": "./_defs.schema.json#/$defs/bool"
},
"bpm": {
"$ref": "./_defs.schema.json#/$defs/float"
},
"timeSigNum": {
"$ref": "./_defs.schema.json#/$defs/int"
},
"timeSigDen": {
"$ref": "./_defs.schema.json#/$defs/int"
},
"positionBeats": {
"$ref": "./_defs.schema.json#/$defs/float"
},
"loop": {
"$ref": "./_defs.schema.json#/$defs/bool"
},
"loopStartBeats": {
"$ref": "./_defs.schema.json#/$defs/float"
},
"loopEndBeats": {
"$ref": "./_defs.schema.json#/$defs/float"
}
},
"required": [
"bpm"
]
}