summaryrefslogtreecommitdiff
path: root/src/encoder/plugins
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2016-04-30 13:57:09 +0200
committerMax Kellermann <max@duempel.org>2016-04-30 13:57:09 +0200
commitc9553411bbcff6471d0877abb2e0acc4ca3f3abb (patch)
tree57acbaf5427b033c2bf988777f4df817c391f900 /src/encoder/plugins
parent62221adf55c8ade22961dd9d76a591a1f3167396 (diff)
encoder/wave: add constant WAVE_FORMAT_PCM
Diffstat (limited to 'src/encoder/plugins')
-rw-r--r--src/encoder/plugins/WaveEncoderPlugin.cxx4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/encoder/plugins/WaveEncoderPlugin.cxx b/src/encoder/plugins/WaveEncoderPlugin.cxx
index ff3deaa04..c20069d9f 100644
--- a/src/encoder/plugins/WaveEncoderPlugin.cxx
+++ b/src/encoder/plugins/WaveEncoderPlugin.cxx
@@ -27,6 +27,8 @@
#include <assert.h>
#include <string.h>
+static constexpr uint16_t WAVE_FORMAT_PCM = 1;
+
struct WaveEncoder {
Encoder encoder;
unsigned bits;
@@ -65,7 +67,7 @@ fill_wave_header(struct wave_header *header, int channels, int bits,
header->id_data = ToLE32(0x61746164);
/* wave format */
- header->format = ToLE16(1); // PCM_FORMAT
+ header->format = ToLE16(WAVE_FORMAT_PCM);
header->channels = ToLE16(channels);
header->bits = ToLE16(bits);
header->freq = ToLE32(freq);