8000 Fix undefined behavior causing WAV files to be unrecognized by nyanpasu64 · Pull Request #14 · Optiroc/BRRtools · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Fix undefined behavior causing WAV files to be unrecognized #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nyanpasu64
Copy link
Contributor

gcc (GCC) 11.2.0 produced a binary which treated even valid .wav files as Input file in unsupported format : "WAVEfmt" block missing !. This change fixes that.

This is the minimum work necessary to make the project build and run; it seems to work in practice. There's still some compiler warnings left, and maybe UB-type bugs in the code as well (I didn't test valgrind/asan yet). Also, IIRC the BRR decoder is incorrect and causes the encoder to generate incorrect BRR files in some edge cases, which decode properly in brr_decoder but not in accurate emulators (in rare circumstances, eg. when Gaussian filtering or resampling produces internal values beyond ±32k), probably related to #13.

@jeffythedragonslayer
Copy link

Cool. What does the "sc" in wave_sc1 stand for?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0