From 2d4453968d67af5cfee81c09adcc7b1ac6bd03f6 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Tue, 21 Sep 2010 09:43:35 -0700 Subject: Implement AL_SOFT_buffer_sub_data using the current AL_EXT_buffer_sub_data spec This extension can be useful for some applications, but a full EXT version may not be ready for some time. Using the SOFT moniker will help differentiate it in case changes need to be done for the EXT version. --- OpenAL32/alSource.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'OpenAL32/alSource.c') diff --git a/OpenAL32/alSource.c b/OpenAL32/alSource.c index 21a4a6eb..c9051793 100644 --- a/OpenAL32/alSource.c +++ b/OpenAL32/alSource.c @@ -1012,8 +1012,8 @@ AL_API ALvoid AL_APIENTRY alGetSourcefv(ALuint source, ALenum eParam, ALfloat *p alGetSource3f(source, eParam, pflValues+0, pflValues+1, pflValues+2); break; - case AL_SAMPLE_RW_OFFSETS_EXT: - case AL_BYTE_RW_OFFSETS_EXT: + case AL_SAMPLE_RW_OFFSETS_SOFT: + case AL_BYTE_RW_OFFSETS_SOFT: updateLen = (ALdouble)pContext->Device->UpdateSize / pContext->Device->Frequency; GetSourceOffset(Source, eParam, Offsets, updateLen); @@ -1248,8 +1248,8 @@ AL_API void AL_APIENTRY alGetSourceiv(ALuint source, ALenum eParam, ALint* plVal alGetSource3i(source, eParam, plValues+0, plValues+1, plValues+2); break; - case AL_SAMPLE_RW_OFFSETS_EXT: - case AL_BYTE_RW_OFFSETS_EXT: + case AL_SAMPLE_RW_OFFSETS_SOFT: + case AL_BYTE_RW_OFFSETS_SOFT: updateLen = (ALdouble)pContext->Device->UpdateSize / pContext->Device->Frequency; GetSourceOffset(Source, eParam, Offsets, updateLen); @@ -1873,12 +1873,12 @@ static ALvoid GetSourceOffset(ALsource *Source, ALenum name, ALdouble *offset, A offset[1] = (ALdouble)writePos / (Channels * Bytes * BufferFreq); break; case AL_SAMPLE_OFFSET: - case AL_SAMPLE_RW_OFFSETS_EXT: + case AL_SAMPLE_RW_OFFSETS_SOFT: offset[0] = (ALdouble)(readPos / (Channels * Bytes)); offset[1] = (ALdouble)(writePos / (Channels * Bytes)); break; case AL_BYTE_OFFSET: - case AL_BYTE_RW_OFFSETS_EXT: + case AL_BYTE_RW_OFFSETS_SOFT: // Take into account the original format of the Buffer if((OriginalFormat == AL_FORMAT_MONO_IMA4) || (OriginalFormat == AL_FORMAT_STEREO_IMA4)) -- cgit v1.2.3