1
0

template.c: make byte_rate a 32-bit variable

This commit is contained in:
Intel A80486DX2-66 2023-11-21 19:17:50 +03:00
parent 3517473605
commit e657f21f37
Signed by: 80486DX2-66
GPG Key ID: 83631EF27054609B

View File

@ -203,10 +203,10 @@ main(int argc, char** argv)
PRODUCT /* sample data */,
fmt_data_length = 16 /* length of format data before this value
in the file format structure */,
sample_rate = SAMPLE_RATE;
sample_rate = SAMPLE_RATE,
byte_rate = (SAMPLE_RATE * BIT_DEPTH * CHANNELS) / 8;
const uint16_t fmt_type = 1, // format type is PCM
channels = CHANNELS,
byte_rate = (SAMPLE_RATE * BIT_DEPTH * CHANNELS) / 8,
block_align = (BIT_DEPTH * CHANNELS) / 8,
bit_depth = BIT_DEPTH > 8 ? BIT_DEPTH : 8;