diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/library_openal.js | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/library_openal.js b/src/library_openal.js index a1ce6f82..58b394ba 100644 --- a/src/library_openal.js +++ b/src/library_openal.js @@ -253,6 +253,18 @@ var LibraryOpenAL = { } }, + alSourcePlay: function(source) { + if (!AL.currentContext) { + console.error("alSourceQueueBuffers called without a valid context"); + return; + } + if (source > AL.currentContext.src.length) { + console.error("alSourceQueueBuffers called with an invalid source"); + return; + } + AL.currentContext.src[source - 1].src.start(0); + }, + alDistanceModel: function(model) { if (model != 0 /* AL_NONE */) { console.log("Only alDistanceModel(AL_NONE) is currently supported"); |