Options
All
  • Public
  • Public/Protected
  • All
Menu

Audio capture using an audio worklet processor.

Hierarchy

Index

Constructors

constructor

  • new AudioCaptureAWP(_ac: AudioContext & { rteHaveCapWorklet?: boolean }, _input: AudioNode): AudioCaptureAWP

Methods

close

  • close(): void

emitEvent

  • emitEvent(ev: string, arg: any): void
  • Emit this event.

    Parameters

    • ev: string

      Event name to emit.

    • arg: any

      Argument to the event handler(s).

    Returns void

getSampleRate

  • getSampleRate(): number

getVADState

init

  • init(): Promise<void>
  • You must initialize an AudioCaptureAWP before it's usable.

    Returns Promise<void>

off

on

  • Set an event handler.

    Parameters

    • ev: string

      Event name, or "*" for all events.

    • handler: EventHandler

      Event handler for this event.

    Returns void

once

  • Set a one-time event handler.

    Parameters

    • ev: string

      Event name, or "*" for all events.

    • handler: EventHandler

      Event handler for this event.

    Returns void

pipe

  • pipe(to: MessagePort): void
  • Redirect data to this MessagePort. This may suppress all future "data" messages, or may not.

    Parameters

    • to: MessagePort

    Returns void

tee

Generated using TypeDoc