The context associated with the time value. Used to compute Transport and context-relative timing.
Optionalvalue: TimeValueThe time value as a number, string or object
Optionalunits: FrequencyUnitUnit values
ReadonlycontextSet this debug flag to log all events that happen in this class.
ReadonlydefaultThe default units
ReadonlynameThe name of the class
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.
StaticA4The concert tuning pitch which is used to generate all the other pitch values from notes. A4's values in Hertz.
disconnect and dispose.
Coerce a time type into this units type.
Any time type units
Takes an array of semitone intervals and returns an array of frequencies transposed by those intervals.
Returns an array of Frequencies
Quantize the time by the given subdivision. Optionally add a percentage which will move the time value towards the ideal quantized value by that percentage.
Return the time encoded as Bars:Beats:Sixteenths.
Return the value of the frequency as a MIDI note
Return the time in milliseconds.
Convert a Time to Notation. The notation values are will be the closest representation between 1m to 128th note.
Return the value of the frequency in Scientific Pitch Notation
Return the time in samples
Return the duration of one cycle in seconds.
Return the duration of one cycle in ticks
Transposes the frequency by the given number of semitones.
A new transposed MidiClass
Evaluate the time value. Returns the time in seconds.
StaticftomConvert a frequency value to a MIDI note.
The value to frequency value to convert.
StaticgetReturns all of the default options belonging to the class.
StaticmtofConvert a MIDI note to frequency value.
The midi number to convert.
The corresponding frequency value
Midi is a primitive type for encoding Time values. Midi can be constructed with or without the
newkeyword. Midi can be passed into the parameter of any method which takes time as an argument.