DCMeter
class Component ↳ extends MeterBase<DCMeterOptions>
DCMeter gets the raw value of the input signal at the current time.
const meter = new Tone.DCMeter(); const mic = new Tone.UserMedia(); mic.open(); // connect mic to the meter mic.connect(meter); // the current level of the mic const level = meter.getValue();
See also: Meter.
Constructor
Section titled “Constructor”new DCMeter(options?: Partial<ToneWithContextOptions>)Parameters
- options
Partial<ToneWithContextOptions>optional
Properties
Section titled “Properties”output
Section titled “output”↳ inherited from MeterBase
output: OutputNodeThe output is just a pass through of the input
Methods
Section titled “Methods”dispose()
Section titled “dispose()”↳ inherited from MeterBase
dispose(): thisDispose and disconnect
Returns this
getValue()
Section titled “getValue()”getValue(): numberGet the signal value of the incoming signal
Returns number
Inherited members
Section titled “Inherited members”- From
ToneWithContext: context, blockTime, sampleTime, get(), immediate(), now(), set(), toFrequency(), toSeconds(), toTicks(), getDefaults() - From
Tone: debug, version, disposed, toString() - From
ToneAudioNode: channelCount, channelCountMode, channelInterpretation, numberOfInputs, numberOfOutputs, chain(), connect(), disconnect(), fan(), toDestination(), toMaster()