[Audio 6/?] Build Soundfonts and the Soundfont Table (#1675)

* [Audio 6/?] Build Soundfonts and the Soundfont Table

* Fix bss

* Maybe fix warnings

* Improve lots of error messages

* Suggested changes from OoT PR

* Suggested changes

* Make soundfont_table.h generation depend on the samplebank xmls since they are read, report from which soundfont the invalid pointer indirect warning originates from
This commit is contained in:
Tharo
2024-08-28 02:09:48 +01:00
committed by GitHub
parent 98d9571f51
commit 7210cfac2f
28 changed files with 2776 additions and 50 deletions
+2 -2
View File
@@ -1252,7 +1252,7 @@ vadpcm_dec(container_data *ctnr, UNUSED const codec_spec *codec, const enc_dec_o
assert(memcmp(input, encoded, frame_size) == 0);
} else {
fails++;
error("FAIL [%d/%d]\n", cur_pos, nSamples);
error("FAIL [%d/%d]", cur_pos, nSamples);
}
// Bring the match closer to the original decode (not strictly
@@ -1284,7 +1284,7 @@ vadpcm_dec(container_data *ctnr, UNUSED const codec_spec *codec, const enc_dec_o
}
if (fails != 0)
error("Decoding failures: %d\n", fails);
error("Decoding failures: %d", fails);
// Convert VADPCM loop to regular loop, if it exists
+2 -2
View File
@@ -486,7 +486,7 @@ aiff_aifc_common_read(container_data *out, FILE *in, UNUSED bool matching, uint3
long read_size = ftell(in) - start - 8;
if (read_size > chunk_size)
error("overran chunk: %lu vs %u\n", read_size, chunk_size);
error("overran chunk: %lu vs %u", read_size, chunk_size);
else if (read_size < chunk_size)
warning("did not read entire %.*s chunk: %lu vs %u", 4, cc4, read_size, chunk_size);
@@ -589,7 +589,7 @@ aiff_aifc_common_write(container_data *in, const char *path, bool aifc, bool mat
{
FILE *out = fopen(path, "wb");
if (out == NULL)
error("Failed to open %s for writing\n", path);
error("Failed to open %s for writing", path);
const char *aifc_head = "FORM\0\0\0\0AIFC";
const char *aiff_head = "FORM\0\0\0\0AIFF";