mirror of
https://github.com/tangerineturtle1/NX2navi.git
synced 2026-11-18 00:29:58 -04:00
Play the game's own interface sounds in the settings menu.
Opening and closing the menu, moving the cursor, changing a value, pressing an item, cancelling a dialog and changing tabs play the game's system sounds (Plus menu open and close, cursor, decide, cancel, tab move), read from the user's RomFS at the first use and decoded from BWAV (DSP-ADPCM or PCM16, 48 kHz) in runtime/menu_sound.c. They are mixed over the game's output in the audio callback with up to eight voices started without locks. The Sound tab gets a Menu sounds volume (menu_sound_volume, 0 to 100, default 80, under the output volume). A RomFS without the files stays silent. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -32,6 +32,7 @@ uint32_t romfs_open(uint64_t *out, const char *path, int mode);
|
||||
uint32_t romfs_read(uint64_t *out, uint64_t h, int64_t offset, void *buffer, uint64_t size);
|
||||
uint32_t romfs_size(int64_t *out, uint64_t h);
|
||||
void romfs_close(uint64_t h);
|
||||
uint8_t *romfs_load(const char *rel, uint64_t *size_out); // whole file by RomFS-relative path, malloc'd (or NULL)
|
||||
uint32_t romfs_entry_type(int *out, const char *path);
|
||||
// The children of RomFS directory path: fn(name, is_dir, size, ctx) once per file and once per subdirectory, in
|
||||
// index order; fn returns 0 to stop. FS_R_PATH_NOT_FOUND when path is not a directory.
|
||||
|
||||
Reference in New Issue
Block a user