shithub: sox

Download patch

ref: 07d690739839a9e455d17e21da85212cf820a0e6
parent: 30f28d2e977f59596df0ffc7fd786fadca98bdd1
author: Mans Rullgard <mans@mansr.com>
date: Fri Aug 7 14:12:47 EDT 2020

wav: drop parentheses and suffix from format tag macros

The parentheses and U suffix are unnecessary and make the numbers
harder to read.

--- a/src/wav.c
+++ b/src/wav.c
@@ -35,27 +35,27 @@
  */
 #define MS_UNSPEC 0x7ffff000
 
-#define WAVE_FORMAT_UNKNOWN             (0x0000U)
-#define WAVE_FORMAT_PCM                 (0x0001U)
-#define WAVE_FORMAT_ADPCM               (0x0002U)
-#define WAVE_FORMAT_IEEE_FLOAT          (0x0003U)
-#define WAVE_FORMAT_ALAW                (0x0006U)
-#define WAVE_FORMAT_MULAW               (0x0007U)
-#define WAVE_FORMAT_OKI_ADPCM           (0x0010U)
-#define WAVE_FORMAT_IMA_ADPCM           (0x0011U)
-#define WAVE_FORMAT_DIGISTD             (0x0015U)
-#define WAVE_FORMAT_DIGIFIX             (0x0016U)
-#define WAVE_FORMAT_DOLBY_AC2           (0x0030U)
-#define WAVE_FORMAT_GSM610              (0x0031U)
-#define WAVE_FORMAT_ROCKWELL_ADPCM      (0x003bU)
-#define WAVE_FORMAT_ROCKWELL_DIGITALK   (0x003cU)
-#define WAVE_FORMAT_G721_ADPCM          (0x0040U)
-#define WAVE_FORMAT_G728_CELP           (0x0041U)
-#define WAVE_FORMAT_MPEG                (0x0050U)
-#define WAVE_FORMAT_MPEGLAYER3          (0x0055U)
-#define WAVE_FORMAT_G726_ADPCM          (0x0064U)
-#define WAVE_FORMAT_G722_ADPCM          (0x0065U)
-#define WAVE_FORMAT_EXTENSIBLE          (0xfffeU)
+#define WAVE_FORMAT_UNKNOWN             0x0000
+#define WAVE_FORMAT_PCM                 0x0001
+#define WAVE_FORMAT_ADPCM               0x0002
+#define WAVE_FORMAT_IEEE_FLOAT          0x0003
+#define WAVE_FORMAT_ALAW                0x0006
+#define WAVE_FORMAT_MULAW               0x0007
+#define WAVE_FORMAT_OKI_ADPCM           0x0010
+#define WAVE_FORMAT_IMA_ADPCM           0x0011
+#define WAVE_FORMAT_DIGISTD             0x0015
+#define WAVE_FORMAT_DIGIFIX             0x0016
+#define WAVE_FORMAT_DOLBY_AC2           0x0030
+#define WAVE_FORMAT_GSM610              0x0031
+#define WAVE_FORMAT_ROCKWELL_ADPCM      0x003b
+#define WAVE_FORMAT_ROCKWELL_DIGITALK   0x003c
+#define WAVE_FORMAT_G721_ADPCM          0x0040
+#define WAVE_FORMAT_G728_CELP           0x0041
+#define WAVE_FORMAT_MPEG                0x0050
+#define WAVE_FORMAT_MPEGLAYER3          0x0055
+#define WAVE_FORMAT_G726_ADPCM          0x0064
+#define WAVE_FORMAT_G722_ADPCM          0x0065
+#define WAVE_FORMAT_EXTENSIBLE          0xfffe
 
 /* To allow padding to samplesPerBlock. Works, but currently never true. */
 static const size_t pad_nsamps = sox_false;