Class StreamModule

This class is for processing sound data from WebRTC.

Hierarchy (view full)

Constructors

Properties

analyser: Analyser
autopanner: Autopanner
bitcrusher: BitCrusher
chorus: Chorus
compressor: Compressor
context: AudioContext
delay: Delay
envelopegenerator: EnvelopeGenerator
equalizer: Equalizer
filter: Filter
flanger: Flanger
fuzz: Fuzz
listener: Listener
mastervolume: GainNode
mixed: boolean = false
modules: Connectable[] = []
noisegate: NoiseGate
noisesuppressor: NoiseSuppressor
overdrive: OverDrive
panner: Panner
phaser: Phaser
pitchshifter: PitchShifter
preamp: Preamp
processor: AudioWorkletNode
recorder: Recorder
reverb: Reverb
ringmodulator: Ringmodulator
runningAnalyser: boolean = false
stereo: Stereo
tremolo: Tremolo
vocalcanceler: VocalCanceler
wah: Wah
NUMBER_OF_INPUTS = 2
NUMBER_OF_OUTPUTS = 2

Accessors

Methods

  • This method gets available devices as array that contains instance of MediaDeviceInfo.

    Returns Promise<void | MediaDeviceInfo[]>

    Return value is Promise that has array contains instance of MediaDeviceInfo.

  • This method gets instance of MediaStream.

    Returns null | MediaStream

  • This method re-initials modules.

    Parameters

    • context: AudioContext

      This argument is in order to use Web Audio API.

    Returns void

  • This method opens devices or sets instance of MediaStream.

    Parameters

    • Optionalparams: {
          errorCallback?: ((error: Error) => void);
          stream?: MediaStream;
          successCallback?: ((stream: MediaStream) => void);
      }
      • OptionalerrorCallback?: ((error: Error) => void)
          • (error): void
          • Parameters

            • error: Error

            Returns void

      • Optionalstream?: MediaStream
      • OptionalsuccessCallback?: ((stream: MediaStream) => void)
          • (stream): void
          • Parameters

            • stream: MediaStream

            Returns void

    Returns Promise<Error | MediaStream>

    Return value is Promise that getUserMedia returns.

  • This method sets up for using WebRTC.

    Parameters

    • Optionalconstraints: MediaStreamConstraints

      This argument is object based on MediaStreamConstraints dictionary.

    Returns StreamModule

    Return value is for method chain.

  • This method determines whether streaming is active.

    Returns boolean

    If streaming is active, this value is true. Otherwise, this value is false.