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: TimeBaseUnitUnit 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.
disconnect and dispose.
Coerce a time type into this units type.
Any time type units
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 in hertz
Return the value 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 time in samples
Return the time in seconds
Return the time in ticks
Evaluate the time value. Returns the time in seconds.
StaticgetReturns all of the default options belonging to the class.
Ticks is a primitive type for encoding Time values. Ticks can be constructed with or without the
newkeyword. Ticks can be passed into the parameter of any method which takes time as an argument.Example