1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-12-16 09:31:14 +01:00

Locate and position the current Audacity source code, and clear a variety of old junk out of the way into junk-branches

This commit is contained in:
ra
2010-01-23 19:44:49 +00:00
commit e74978ba77
1011 changed files with 781704 additions and 0 deletions

58
src/RingBuffer.h Normal file
View File

@@ -0,0 +1,58 @@
/**********************************************************************
Audacity: A Digital Audio Editor
RingBuffer.h
Dominic Mazzoni
*******************************************************************/
#ifndef __AUDACITY_RING_BUFFER__
#define __AUDACITY_RING_BUFFER__
#include "SampleFormat.h"
class RingBuffer {
public:
RingBuffer(sampleFormat format, int size);
~RingBuffer();
//
// For the writer only:
//
int AvailForPut();
int Put(samplePtr buffer, sampleFormat format, int samples);
//
// For the reader only:
//
int AvailForGet();
int Get(samplePtr buffer, sampleFormat format, int samples);
int Discard(int samples);
private:
int Len();
sampleFormat mFormat;
int mStart;
int mEnd;
int mBufferSize;
samplePtr mBuffer;
};
#endif /* __AUDACITY_RING_BUFFER__ */
// Indentation settings for Vim and Emacs and unique identifier for Arch, a
// version control system. Please do not modify past this point.
//
// Local Variables:
// c-basic-offset: 3
// indent-tabs-mode: nil
// End:
//
// vim: et sts=3 sw=3
// arch-tag: 43b69817-059c-4f4a-87e5-b19b2bcc75fb