Store the bufferID in the buffer struct
[openal-soft.git] / OpenAL32 / Include / alBuffer.h
blobb7d366420968179b284cf4c842a241e5bf8ee0d8
1 #ifndef _AL_BUFFER_H_
2 #define _AL_BUFFER_H_
4 #include "AL/al.h"
6 #ifdef __cplusplus
7 extern "C" {
8 #endif
10 #define UNUSED 0
11 #define PENDING 1
12 #define PROCESSED 2
14 typedef struct ALbuffer
16 ALenum format;
17 ALenum eOriginalFormat;
19 ALshort *data;
20 ALsizei size;
22 ALsizei frequency;
23 ALsizei padding;
24 ALenum state;
26 ALuint refcount; // Number of sources using this buffer (deletion can only occur when this is 0)
28 // Index to itself
29 ALuint buffer;
31 struct ALbuffer *next;
32 } ALbuffer;
34 ALvoid ALAPIENTRY alBufferSubDataEXT(ALuint buffer,ALenum format,const ALvoid *data,ALsizei offset,ALsizei length);
36 ALvoid ReleaseALBuffers(ALCdevice *device);
38 #ifdef __cplusplus
40 #endif
42 #endif