diff options
author | Stijn Buys <ingar@osirion.org> | 2011-04-17 14:21:29 +0000 |
---|---|---|
committer | Stijn Buys <ingar@osirion.org> | 2011-04-17 14:21:29 +0000 |
commit | 09d68d3d1d77d45343e3562c0b5e0cd6816d47d3 (patch) | |
tree | 6b89c585fe8cd8bd49699cdb349566d3f382010e /src/audio/pcm.h | |
parent | 8264546908f1722b4d0f0e91c42dd791ba8535c4 (diff) |
Initial Ogg Vorbis sounds effect support.
Diffstat (limited to 'src/audio/pcm.h')
-rw-r--r-- | src/audio/pcm.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/audio/pcm.h b/src/audio/pcm.h index 8df44e8..62052bf 100644 --- a/src/audio/pcm.h +++ b/src/audio/pcm.h @@ -21,6 +21,12 @@ public: ~PCM(); void clear(); + + /// set the data size + void set_size(size_t size); + + /// grow the buffer + void grow(size_t size); /// pointer to the raw pcm data inline unsigned char *data() { @@ -32,7 +38,12 @@ public: return &pcm_data[index]; } - /// size in bytes + /// size of the buffer + inline size_t buff_size() { + return pcm_buff_size; + } + + /// size of the audio data, in bytes inline size_t size() { return pcm_size; } @@ -59,6 +70,7 @@ private: unsigned int pcm_samplerate; unsigned int pcm_bitspersample; size_t pcm_size; + size_t pcm_buff_size; }; } |