From 6636131d3bb52687229881d4d2343b5c464b5c81 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Tue, 15 Sep 2009 18:19:00 -0700 Subject: Pass the frame count to aluMixData --- Alc/solaris.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'Alc/solaris.c') diff --git a/Alc/solaris.c b/Alc/solaris.c index 9ac00d8d..8ea190e6 100644 --- a/Alc/solaris.c +++ b/Alc/solaris.c @@ -54,15 +54,19 @@ static ALuint SolarisProc(ALvoid *ptr) ALCdevice *pDevice = (ALCdevice*)ptr; solaris_data *data = (solaris_data*)pDevice->ExtraData; int remaining = 0; + ALint frameSize; int wrote; + frameSize = aluChannelsFromFormat(pDevice->Format) * + aluBytesFromFormat(pDevice->Format); + while(!data->killNow && !pDevice->Connected) { ALint len = data->data_size; ALubyte *WritePtr = data->mix_data; SuspendContext(NULL); - aluMixData(pDevice->Context, WritePtr, len, pDevice->Format); + aluMixData(pDevice->Context, WritePtr, len/frameSize, pDevice->Format); ProcessContext(NULL); while(len > 0 && !data->killNow) -- cgit v1.2.3