mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-01-19 00:04:04 +01:00
Add brwsd & brwav ext. Fix RWSD for Wii Sports
This commit is contained in:
parent
9ef1030dfd
commit
30ab06b109
@ -118,6 +118,8 @@ static const char* extension_list[] = {
|
||||
"bo2",
|
||||
"brstm",
|
||||
"brstmspm",
|
||||
"brwav",
|
||||
"brwsd",
|
||||
"bsnd",
|
||||
"btsnd",
|
||||
"bvg",
|
||||
|
@ -11,13 +11,13 @@ VGMSTREAM* init_vgmstream_rwsd(STREAMFILE* sf) {
|
||||
size_t wave_length;
|
||||
int codec, channels, loop_flag;
|
||||
size_t stream_size;
|
||||
off_t start_offset, wave_offset = 0;
|
||||
off_t start_offset, wave_offset = 0, labl_offset;
|
||||
|
||||
|
||||
if (!is_id32be(0x00, sf, "RWSD"))
|
||||
goto fail;
|
||||
|
||||
if (!check_extensions(sf, "rwsd"))
|
||||
if (!check_extensions(sf, "brwsd,rwsd"))
|
||||
goto fail;
|
||||
|
||||
/* check header */
|
||||
@ -98,6 +98,11 @@ VGMSTREAM* init_vgmstream_rwsd(STREAMFILE* sf) {
|
||||
|
||||
/* this is just data size and following data may or may not be from this RWSD */
|
||||
start_offset = read_32bitBE(0x08, sf);
|
||||
if (is_id32be(start_offset, sf, "LABL")) {
|
||||
labl_offset = start_offset;
|
||||
start_offset += read_32bitBE(start_offset + 0x04, sf);
|
||||
read_string(vgmstream->stream_name, 0x28, labl_offset + 0x18, sf);
|
||||
}
|
||||
|
||||
stream_size = read_32bitBE(wave_offset + 0x50,sf);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user