sw-synth
    Preparing search index...

    Class UnisonSynth

    Web audio synth of finite polyphony where the voices are stacked in unison.

    Hierarchy (View Summary)

    Index

    Constructors

    • Parameters

      • audioContext: BaseAudioContext
      • destination: AudioNode
      • Optionallog: (msg: string) => void

      Returns UnisonSynth

    Properties

    audioContext: BaseAudioContext
    destination: AudioNode
    log: (msg: string) => void
    pitchBend: AudioParam
    voiceParams?: UnisonVoiceParams
    voices: UnisonVoice[]

    Accessors

    • get maxPolyphony(): number

      Returns number

    • set maxPolyphony(value: number): void

      Parameters

      • value: number

      Returns void

    Methods

    • Trigger panic and release all notes.

      Returns void

    • Start playing a note at the specified frequency and velocity.

      Parameters

      • frequency: number

        Frequency in Hertz.

      • velocity: number

        Voice amplitude. Recommended range is 0 to 1.

      • OptionalpitchBendRange: PitchBendRange

        Asymmetric pitch bend range. Determines the effect of Synth.pitchBend on this note.

      Returns () => void

      A callback that stops playing the note.

    • Parameters

      • maxPolyphony: number

      Returns void