diff options
author | Chris Robinson <[email protected]> | 2009-09-16 22:58:54 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2009-09-16 22:58:54 -0700 |
commit | cbcaa54173bf6b14435adf3daf9feb2fa2e37d04 (patch) | |
tree | a56832a1ee9f96e72ac03a0424893714794cae4a /Alc/solaris.c | |
parent | 94e3fca7022c5c7f8147200ffdb3cda5ded62488 (diff) |
Store the number of periods in the device instead of the buffer size
Also keep all the fields in sync
Diffstat (limited to 'Alc/solaris.c')
-rw-r--r-- | Alc/solaris.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Alc/solaris.c b/Alc/solaris.c index 5cc9e201..58d6e081 100644 --- a/Alc/solaris.c +++ b/Alc/solaris.c @@ -167,7 +167,7 @@ static ALCboolean solaris_reset_playback(ALCdevice *device) info.play.channels = numChannels; frameSize = numChannels * aluBytesFromFormat(device->Format); - info.play.buffer_size = device->BufferSize * frameSize; + info.play.buffer_size = device->UpdateSize*device->NumUpdates * frameSize; if(ioctl(data->fd, AUDIO_SETINFO, &info) < 0) { @@ -189,7 +189,7 @@ static ALCboolean solaris_reset_playback(ALCdevice *device) } device->Frequency = info.play.sample_rate; - device->UpdateSize = info.play.buffer_size / 4; + device->UpdateSize = (info.play.buffer_size/device->NumUpdates) + 1; data->data_size = device->UpdateSize * frameSize; data->mix_data = calloc(1, data->data_size); |