Repository

Buffer

Constructor Summary

Public Constructor
public

Buffer Class.

Member Summary

Public Members
public
public
public
public

Method Summary

Public Methods
public

Return the underlying WebAudio audio buffer

Public Constructors

public constructor(params: Object) source

Buffer Class. Encapsulates the concept of buffer of Audio data. You can load, depending on the platform, various audio file formats, like WAV, MP3 or OGG. See the Web Audio API documentation. Requires the Web Audio API.

Params:

NameTypeAttributeDescription
paramsObject

the parameters object

params.rendererRendererAudio
  • optional
  • default: new Renderer()

The audio renderer

params.arrayBufferArrayBuffer

the raw arraybuffer, already loaded, to give to the audio context

params.decodedCallbackFunction

the callback function to call when Audio Context has decoded the sound file's raw arrayBuffer

Public Members

public arrayBuffer: * source

public decodedCallback: * source

public nativeAudioBuffer: * source

public renderer: * source

Public Methods

public getNativeBuffer(): Buffer source

Return the underlying WebAudio audio buffer

Return:

Buffer

webAudio buffer