Less naive double-buffer reading

Use memcpy instead of complicated byte-by-byte operations to read data
out of the buffer.  Should allow for somewhat faster reads.
This commit is contained in:
Earle F. Philhower, III committed 2017-11-15 13:17:43 -08:00
1 parent 07531b905e
commit 65c1373300
2 files changed
+26 -11

No files matched your search

+4 -4
View File
@@ -39,11 +39,11 @@ class AudioFileSourceBuffer : public AudioFileSource
private:
AudioFileSource *src;
int buffSize;
uint16_t buffSize;
uint8_t *buffer;
int writePtr;
int readPtr;
int length;
uint16_t writePtr;
uint16_t readPtr;
uint16_t length;
bool filled;
};