typedef struct {
ID chunkID;
long chunkSize;
short wFormatTag;
unsigned short wChannels;
unsigned long dwSamplesPerSec;
unsigned long dwAvgBytesPerSec;
unsigned short wBlockAlign;
unsigned short wBitsPerSample;
/* Note: there may be additional fields here, depending upon wFormatTag. */
} FormatChunk;
typedef struct {
ID chunkID;
long chunkSize;
unsigned char waveformData[];
} DataChunk;
You could always define wFormatTag=1, as if audio data were compressed, set chunkSize to 0xFFFFFFFF, and then store the actual size in the compressed file info.
But then, you could not store the real size in DataChunk, because there's not enough room. Or you could use a spacial value of wFormatTag, that would trigger various changes in the format.
Anyway, none of these changes would be compatible with existing apps
Then, instead of redefining two data structures in an incompatible way, why not use mka ?