8 bit, and ADPCM wav files sound like garbage, so disabling it.
Changed directory to "MUSIC".
Minor changes to file selector.
Signed-off-by: Mahyar Koshkouei <deltabeard@users.noreply.github.com>
Added work-around for stereo WAV files. Plays them twice as fast to
compensate for the fact the player currently only supporting monophonic
output. Stereo output will be added in the future.
WAV sampling rate, resolution, channels, etc is now automatically
detected. Note that 8bit WAV files sound horrible for some reason.
Note that PCM WAV files are supported, not compressed WAV files.
Tested working on n3DS and 3DS.
Signed-off-by: Mahyar Koshkouei <deltabeard@users.noreply.github.com>
Fixed an issue where the first part of a WAV file would not be played.
Fixed an issue where a random part of the WAV file would play after the
file had finished playing.
Fixed an issue where the audio file was not closed after it had finished
playing.
Fixed an issue whereby the current file would continue playing after
returning to the main menu.
Added basic file selector to select different WAV audio files in the
/audio/ folder.
Now using two buffers to play audio. Whilst one buffer is playing, the
other buffer is played. Buffer size set to a magic value of 1MiB.
Tested on New 3DS. Currently working with 48000Hz, 16 Bit WAV files.
TODO (in order):
Refactor duplicate code.
Automatically detect WAV sampling rate, resolution, etc.
Remove debug messages.
Add file browser.
Signed-off-by: Mahyar Koshkouei <deltabeard@users.noreply.github.com>
Large WAV files can now be played. Tested working with 77MiB WAV files.
Known issues:
- First kilobytes of WAV file isn't played.
- Screen doesn't turn on after 3DS placed in sleep mode.
Signed-off-by: Mahyar Koshkouei <deltabeard@users.noreply.github.com>