Skip to content

Interface: AnalyserNode ​

Defined in: types/desktop-engine.d.ts:6524

Frequency and waveform data of what passes through, e.g. for visualizers

Extends ​

Properties ​

channelCount ​

ts
channelCount: number;

Defined in: types/desktop-engine.d.ts:6351

1 to 32

Inherited from ​

AudioNode.channelCount


channelCountMode ​

ts
channelCountMode: ChannelCountMode;

Defined in: types/desktop-engine.d.ts:6352

Inherited from ​

AudioNode.channelCountMode


channelInterpretation ​

ts
channelInterpretation: ChannelInterpretation;

Defined in: types/desktop-engine.d.ts:6353

Inherited from ​

AudioNode.channelInterpretation


context ​

ts
readonly context: BaseAudioContext;

Defined in: types/desktop-engine.d.ts:6347

Inherited from ​

AudioNode.context


fftSize ​

ts
fftSize: number;

Defined in: types/desktop-engine.d.ts:6526

A power of 2 from 32 to 32768, 2048 by default


frequencyBinCount ​

ts
readonly frequencyBinCount: number;

Defined in: types/desktop-engine.d.ts:6528

fftSize / 2


maxDecibels ​

ts
maxDecibels: number;

Defined in: types/desktop-engine.d.ts:6530


minDecibels ​

ts
minDecibels: number;

Defined in: types/desktop-engine.d.ts:6529


numberOfInputs ​

ts
readonly numberOfInputs: number;

Defined in: types/desktop-engine.d.ts:6348

Inherited from ​

AudioNode.numberOfInputs


numberOfOutputs ​

ts
readonly numberOfOutputs: number;

Defined in: types/desktop-engine.d.ts:6349

Inherited from ​

AudioNode.numberOfOutputs


smoothingTimeConstant ​

ts
smoothingTimeConstant: number;

Defined in: types/desktop-engine.d.ts:6532

0 to 1

Methods ​

addEventListener() ​

ts
addEventListener(
   type, 
   listener, 
   options?
): void;

Defined in: types/desktop-engine.d.ts:5370

A boolean options (capture) is ignored

Parameters ​

ParameterType
typestring
listener| EventListenerOrEventListenerObject | null
options?| boolean | AddEventListenerOptions

Returns ​

void

Inherited from ​

AudioNode.addEventListener


connect() ​

Call Signature ​

ts
connect<T>(
   destinationNode, 
   output?, 
   input?
): T;

Defined in: types/desktop-engine.d.ts:6355

Connects an output to an input of a node of the same context; returns that node, for chaining

Type Parameters ​
Type Parameter
T extends AudioNode
Parameters ​
ParameterType
destinationNodeT
output?number
input?number
Returns ​

T

Inherited from ​

AudioNode.connect

Call Signature ​

ts
connect(destinationParam, output?): void;

Defined in: types/desktop-engine.d.ts:6357

Adds an output to the param's value

Parameters ​
ParameterType
destinationParamAudioParam
output?number
Returns ​

void

Inherited from ​

AudioNode.connect


disconnect() ​

Call Signature ​

ts
disconnect(): void;

Defined in: types/desktop-engine.d.ts:6359

Disconnects every output, or the outputs / connections given

Returns ​

void

Inherited from ​

AudioNode.disconnect

Call Signature ​

ts
disconnect(output): void;

Defined in: types/desktop-engine.d.ts:6360

Parameters ​
ParameterType
outputnumber
Returns ​

void

Inherited from ​

AudioNode.disconnect

Call Signature ​

ts
disconnect(
   destinationNode, 
   output?, 
   input?
): void;

Defined in: types/desktop-engine.d.ts:6361

Parameters ​
ParameterType
destinationNodeAudioNode
output?number
input?number
Returns ​

void

Inherited from ​

AudioNode.disconnect

Call Signature ​

ts
disconnect(destinationParam, output?): void;

Defined in: types/desktop-engine.d.ts:6362

Parameters ​
ParameterType
destinationParamAudioParam
output?number
Returns ​

void

Inherited from ​

AudioNode.disconnect


dispatchEvent() ​

ts
dispatchEvent(event): boolean;

Defined in: types/desktop-engine.d.ts:5373

Returns false when a listener called preventDefault() on a cancelable event

Parameters ​

ParameterType
eventEvent

Returns ​

boolean

Inherited from ​

AudioNode.dispatchEvent


getByteFrequencyData() ​

ts
getByteFrequencyData(array): void;

Defined in: types/desktop-engine.d.ts:6536

Fills the array with 0-255, minDecibels to maxDecibels, up to frequencyBinCount values

Parameters ​

ParameterType
arrayUint8Array

Returns ​

void


getByteTimeDomainData() ​

ts
getByteTimeDomainData(array): void;

Defined in: types/desktop-engine.d.ts:6540

Fills the array with samples as 0-255 (128 is 0), up to fftSize values

Parameters ​

ParameterType
arrayUint8Array

Returns ​

void


getFloatFrequencyData() ​

ts
getFloatFrequencyData(array): void;

Defined in: types/desktop-engine.d.ts:6534

Fills the array with decibels, up to frequencyBinCount values

Parameters ​

ParameterType
arrayFloat32Array

Returns ​

void


getFloatTimeDomainData() ​

ts
getFloatTimeDomainData(array): void;

Defined in: types/desktop-engine.d.ts:6538

Fills the array with samples, up to fftSize values

Parameters ​

ParameterType
arrayFloat32Array

Returns ​

void


removeEventListener() ​

ts
removeEventListener(type, listener): void;

Defined in: types/desktop-engine.d.ts:5371

Parameters ​

ParameterType
typestring
listener| EventListenerOrEventListenerObject | null

Returns ​

void

Inherited from ​

AudioNode.removeEventListener

The SDK is released under the Apache License 2.0