aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2011-06-12 19:36:28 -0700
committerChris Robinson <[email protected]>2011-06-12 19:36:28 -0700
commit96a18ba1d50d76ec417c1777e825b8c67cd2e884 (patch)
tree28f382a3a85057ebc8c794e99c2527ce733492b8
parentb8bb41107c23cb469de4074887ab09978f8a0f22 (diff)
Make fewer assumptions on the OpenSL buffer count
-rw-r--r--Alc/opensl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Alc/opensl.c b/Alc/opensl.c
index b9d8ffa5..96fb3a0e 100644
--- a/Alc/opensl.c
+++ b/Alc/opensl.c
@@ -259,7 +259,7 @@ static ALCboolean opensl_reset_playback(ALCdevice *Device)
req = SL_BOOLEAN_TRUE;
loc_bufq.locatorType = SL_DATALOCATOR_ANDROIDSIMPLEBUFFERQUEUE;
- loc_bufq.numBuffers = 2;
+ loc_bufq.numBuffers = Device->NumUpdates;
format_pcm.formatType = SL_DATAFORMAT_PCM;
format_pcm.numChannels = 2;
@@ -307,7 +307,7 @@ static ALCboolean opensl_reset_playback(ALCdevice *Device)
}
}
/* enqueue the first buffer to kick off the callbacks */
- for(i = 0;i < loc_bufq.numBuffers;i++)
+ for(i = 0;i < Device->NumUpdates;i++)
{
if(SL_RESULT_SUCCESS == result)
{