Omnitone namespace.
- Source:
Members
(static) browserInfo
An object contains the detected browser name and version.
- Source:
Methods
(static) createBufferList(context, bufferData, optionsopt) → {Promise.<Array.<AudioBuffer>>}
Performs the async loading/decoding of multiple AudioBuffers from multiple
URLs.
Parameters:
Name | Type | Attributes | Description | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
context |
BaseAudioContext | Associated BaseAudioContext. | |||||||||||
bufferData |
Array.<string> | An ordered list of URLs. | |||||||||||
options |
Object |
<optional> |
BufferList options.
Properties
|
- Source:
Returns:
- The promise resolves with an array of
AudioBuffer.
- Type
- Promise.<Array.<AudioBuffer>>
(static) createFOAConvolver(context, hrirBufferListopt) → {FOAConvolver}
Creates an instance of FOA Convolver.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
context |
BaseAudioContext | The associated AudioContext. | |
hrirBufferList |
Array.<AudioBuffer> |
<optional> |
An ordered-list of stereo |
- Source:
- See:
-
- FOAConvolver
Returns:
- Type
- FOAConvolver
(static) createFOARenderer(context, config) → {FOARenderer}
Create a FOARenderer, the first-order ambisonic decoder and the optimized
binaural renderer.
Parameters:
Name | Type | Description | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
context |
AudioContext | Associated AudioContext. | ||||||||||||||||||||
config |
Object |
Properties
|
- Source:
Returns:
- Type
- FOARenderer
(static) createFOARotator(context) → {FOARotator}
Create an instance of FOA Rotator.
Parameters:
Name | Type | Description |
---|---|---|
context |
AudioContext | Associated AudioContext. |
- Source:
- See:
-
- FOARotator
Returns:
- Type
- FOARotator
(static) createFOARouter(context, channelMap) → {FOARouter}
Create an instance of FOA Router.
Parameters:
Name | Type | Description |
---|---|---|
context |
AudioContext | Associated AudioContext. |
channelMap |
Array.<Number> | Routing destination array. |
- Source:
- See:
-
- FOARouter
Returns:
- Type
- FOARouter
(static) createHOAConvolver(context, ambisonicOrder, hrirBufferListopt) → {HOAConvovler}
Creates HOAConvolver performs the multi-channel convolution for the optmized
binaural rendering.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
context |
AudioContext | Associated AudioContext. | |
ambisonicOrder |
Number | Ambisonic order. (2 or 3) | |
hrirBufferList |
Array.<AudioBuffer> |
<optional> |
An ordered-list of stereo AudioBuffers for convolution. (SOA: 5 AudioBuffers, TOA: 8 AudioBuffers) |
- Source:
Returns:
- Type
- HOAConvovler
(static) createHOARenderer(context, config) → {HOARenderer}
Creates HOARenderer for higher-order ambisonic decoding and the optimized
binaural rendering.
Parameters:
Name | Type | Description | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
context |
AudioContext | Associated AudioContext. | ||||||||||||||||||||
config |
Object |
Properties
|
- Source:
Returns:
- Type
- HOARenderer
(static) createHOARotator(context, ambisonicOrder) → {HOARotator}
Creates HOARotator for higher-order ambisonics rotation.
Parameters:
Name | Type | Description |
---|---|---|
context |
AudioContext | Associated AudioContext. |
ambisonicOrder |
Number | Ambisonic order. |
- Source:
Returns:
- Type
- HOARotator
(static) mergeBufferListByChannel(context, bufferList) → {AudioBuffer}
Perform channel-wise merge on multiple AudioBuffers. The sample rate and
the length of buffers to be merged must be identical.
Parameters:
Name | Type | Description |
---|---|---|
context |
BaseAudioContext | Associated BaseAudioContext. |
bufferList |
Array.<AudioBuffer> | An array of AudioBuffers to be merged channel-wise. |
- Source:
Returns:
- A single merged AudioBuffer.
- Type
- AudioBuffer
(static) splitBufferbyChannel(context, audioBuffer, splitBy) → {Array.<AudioBuffer>}
Perform channel-wise split by the given channel count. For example,
1 x AudioBuffer(8) -> splitBuffer(context, buffer, 2) -> 4 x AudioBuffer(2).
Parameters:
Name | Type | Description |
---|---|---|
context |
BaseAudioContext | Associated BaseAudioContext. |
audioBuffer |
AudioBuffer | An AudioBuffer to be splitted. |
splitBy |
Number | Number of channels to be splitted. |
- Source:
Returns:
- An array of splitted AudioBuffers.
- Type
- Array.<AudioBuffer>