nf-player
    Preparing search index...

    Class XAudioBuffer

    An implementation of AudioBuffer as seen in the Web Audio API. The AudioBuffer in Web Audio is tied to the browser, and only recently it became possible to instantiate an AudioBuffer without a Web Audio Context. This implementation allows for a fully WebAudio-free player, while still allowing for easy interop with the Web Audio API when needed when still in a browser environment.

    Originally from https://github.com/audiojs/audio-buffer/, MIT Licensed. Converted to TS. https://github.com/audiojs/audio-buffer/blob/master/LICENSE

    Index

    Constructors

    Properties

    _channelData: Float32Array<ArrayBuffer>[]
    _data: Float32Array<ArrayBuffer>
    duration: number
    length: number
    numberOfChannels: number
    sampleRate: number

    Methods

    • Place data to the destination buffer, starting from the position

      Parameters

      • destination: Float32Array
      • channelNumber: number
      • startInChannel: number = 0

      Returns void

    • Place data from the source to the channel, starting (in self) from the position

      Parameters

      • source: Float32Array
      • channelNumber: number
      • startInChannel: number = 0

      Returns void

    • Return data associated with the channel.

      Parameters

      • channel: number

      Returns Float32Array<ArrayBuffer>