summaryrefslogtreecommitdiffstats
path: root/src/wavfile.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/wavfile.h')
-rw-r--r--src/wavfile.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/wavfile.h b/src/wavfile.h
index 92ea56f..a8cd4d9 100644
--- a/src/wavfile.h
+++ b/src/wavfile.h
@@ -20,6 +20,7 @@
#pragma once
#include <cstdio>
+#include <cstdint>
void* wav_read_open(const char *filename);
void wav_read_close(void* obj);
@@ -29,12 +30,14 @@ int wav_read_data(void* obj, unsigned char* data, unsigned int length);
class WavWriter {
public:
- WavWriter(const char *filename, int rate);
+ WavWriter(const char *filename);
~WavWriter();
WavWriter(const WavWriter& other) = delete;
WavWriter& operator=(const WavWriter& other) = delete;
- void write_data(short *data, int length);
+ void initialise_header(int rate);
+
+ void write_data(const uint8_t *data, int length);
private:
FILE *m_fd = nullptr;