Optionalcallback: ToneEventCallback<ValueType>The callback to invoke with every note
Optionalevents: SequenceEventDescription<ValueType>The sequence of events
Optionalsubdivision: Unit.TimeThe subdivision between which events are placed.
The callback to invoke.
ReadonlycontextThe context belonging to the node.
Set this debug flag to log all events that happen in this class.
If mute is true, the callback won't be invoked.
ReadonlynameThe name of the class
The value which is passed to the callback function.
StaticversionThe version number semver
Indicates if the instance was disposed. 'Disposing' an instance means that all of the Web Audio nodes that were created for the instance are disconnected and freed for garbage collection.
The sequence
The number of scheduled events
If the note should loop or not between ToneEvent.loopStart and ToneEvent.loopEnd. If set to true, the event will loop indefinitely, if set to a number greater than 1 it will play a specific number of times, if set to false, 0 or 1, the part will only play once.
If the note should loop or not between ToneEvent.loopStart and ToneEvent.loopEnd. If set to true, the event will loop indefinitely, if set to a number greater than 1 it will play a specific number of times, if set to false, 0 or 1, the part will only play once.
The index at which the sequence should end looping
The loopEnd point is the time the event will loop if ToneEvent.loop is true.
The index at which the sequence should start looping
The time when the loop should start.
The probability of the notes being triggered.
The probability of the notes being triggered.
The current progress of the loop interval. Returns 0 if the event is not started yet or it is not set to loop.
The duration in seconds of one sample.
The start from the scheduled start time.
The start from the scheduled start time.
Returns the playback state of the note, either "started" or "stopped".
The subdivision of the sequence. This can only be set in the constructor. The subdivision is the interval between successive steps.
Cancel all scheduled events greater than or equal to the given time
Optionaltime: Unit.Time | TransportTimeClass<number>The time after which events will be cancel.
Clear all of the events
Dispose and disconnect
Get the object's attributes.
Set multiple properties at once with an object.
Convert the incoming time to seconds. This is calculated against the current TransportInstance bpm
Staticget
A sequence is an alternate notation of a part. Instead of passing in an array of [time, event] pairs, pass in an array of events which will be spaced at the given subdivision. Sub-arrays will subdivide that beat by the number of items are in the array. Sequence notation inspiration from Tidal Cycles
Example