aboutsummaryrefslogtreecommitdiffstats
path: root/OpenAL32/alBuffer.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2011-08-29 23:05:47 -0700
committerChris Robinson <[email protected]>2011-08-29 23:10:02 -0700
commitcc67f4589256efceb17c58673159b3e687ec0436 (patch)
treefe7c3688ac00bdb6ee0fc9766216ab4b9f9144b8 /OpenAL32/alBuffer.c
parentc6a110ec59c794f08446bd8bb9d90958903984c9 (diff)
Use the reference counting functions for the buffer and auxiliary slot refs
Diffstat (limited to 'OpenAL32/alBuffer.c')
-rw-r--r--OpenAL32/alBuffer.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/OpenAL32/alBuffer.c b/OpenAL32/alBuffer.c
index 7d5b895f..ebcd4724 100644
--- a/OpenAL32/alBuffer.c
+++ b/OpenAL32/alBuffer.c
@@ -221,7 +221,7 @@ AL_API ALvoid AL_APIENTRY alDeleteBuffers(ALsizei n, const ALuint *buffers)
Failed = AL_TRUE;
break;
}
- else if(ALBuf->refcount != 0)
+ else if(ALBuf->ref != 0)
{
/* Buffer still in use, cannot be deleted */
alSetError(Context, AL_INVALID_OPERATION);
@@ -297,7 +297,7 @@ AL_API ALvoid AL_APIENTRY alBufferData(ALuint buffer,ALenum format,const ALvoid
device = Context->Device;
if((ALBuf=LookupBuffer(device->BufferMap, buffer)) == NULL)
alSetError(Context, AL_INVALID_NAME);
- else if(ALBuf->refcount != 0)
+ else if(ALBuf->ref != 0)
alSetError(Context, AL_INVALID_VALUE);
else if(size < 0 || freq < 0)
alSetError(Context, AL_INVALID_VALUE);
@@ -453,7 +453,7 @@ AL_API void AL_APIENTRY alBufferSamplesSOFT(ALuint buffer,
device = Context->Device;
if((ALBuf=LookupBuffer(device->BufferMap, buffer)) == NULL)
alSetError(Context, AL_INVALID_NAME);
- else if(ALBuf->refcount != 0)
+ else if(ALBuf->ref != 0)
alSetError(Context, AL_INVALID_VALUE);
else if(frames < 0 || samplerate == 0)
alSetError(Context, AL_INVALID_VALUE);
@@ -737,7 +737,7 @@ AL_API void AL_APIENTRY alBufferiv(ALuint buffer, ALenum eParam, const ALint* pl
switch(eParam)
{
case AL_LOOP_POINTS_SOFT:
- if(ALBuf->refcount > 0)
+ if(ALBuf->ref != 0)
alSetError(pContext, AL_INVALID_OPERATION);
else if(plValues[0] < 0 || plValues[1] < 0 ||
plValues[0] >= plValues[1] || ALBuf->size == 0)