Tutorial Music RE5 RE6 for Mercenaries + Loop
Aug 7, 2014 9:59:36 GMT 10
Johnny Valentine, ryuhayabusa94, and 1 more like this
Post by Fanboy_Deker on Aug 7, 2014 9:59:36 GMT 10
Tutorial
I used the following tools:
foobar2000
www.foobar2000.org/
HxD
mh-nexus.de/en/hxd/
Audacity
audacity.sourceforge.net/
RE5 Arc Tool v095c
z6.invisionfree.com/Resident_Evil_4...showtopic=10046
The mercenaries music is located here:
nativePC \ sound \ bgm \ oto \ bgm \ s_bgm \ s_bgm020.sngw
First, I rename s_bgm020.sngw to s_bgm020.ogg so I can open it in foobar2000.
Then open it in foobar2000, right click the file and select Properties or use Alt + Enter.
In the Properties tab, look for the key "Duration" and the value should be "1: 35,637 (4,590,592 samples)."
In the Metadata tab, look for "LoopEnd" and "LoopStart" keys.
Values should be "4586496" and "316928". These values are also samples.
RE5 uses the "samples" to define the points song length, loop start and end of the loop.
The definitions file background music can be found here:
CoreResource.arc \ sound \ bgm \ st_bgm.stq
You will need to extract and repackage this file CoreResource.arc using the Arc tool.
You will need a hex editor to edit the file st_bgm.stq.
St_bgm.stq open with HxD hex editor. Press CTRL + F and select "integer" for the type of data and research to 4,590,592, which is the length of song samples. You should reach 44C offset by 4 bytes 00 46 00 0C.
The sample values herein will reverse hexadecimal and 4 bytes in length.
460C00 hex decimal = 4590592 = 00 0C 46 00 hexadecimal reverse
44C Offset: 00 0C 46 00 DURATION = SONG
450 Displacement: 4 bytes of mystery!
454 Displacement: 00 04 00 D6 = LoopStart
458 Displacement: 00 FC 45 00 = LoopEnd
You just edit the byte offsets these with the values of samples of new music that you will use and then the music will circulate properly. Remember the bytes must be hexadecimal otherwise!
I recommend that new song you use to be in lossless format like WAV or FLAC, before converting it to OGG using Audacity. Converting OGG to MP3 × can result in poor sound quality! When exporting to OGG, I use six quality to achieve nominal bit rate 192 which is the same as the music files RE5.
If you do not want to loop music in ogg / sngw file under the Metadata tab, and change the LoopEnd LoopStart values for both -1. Then in stq file, change the bytes to LoopEnd and LoopStart both FF FF FF FF. I replaced the song "You're dead" using this method, because I only wanted to play once.
I used the following tools:
foobar2000
www.foobar2000.org/
HxD
mh-nexus.de/en/hxd/
Audacity
audacity.sourceforge.net/
RE5 Arc Tool v095c
z6.invisionfree.com/Resident_Evil_4...showtopic=10046
The mercenaries music is located here:
nativePC \ sound \ bgm \ oto \ bgm \ s_bgm \ s_bgm020.sngw
First, I rename s_bgm020.sngw to s_bgm020.ogg so I can open it in foobar2000.
Then open it in foobar2000, right click the file and select Properties or use Alt + Enter.
In the Properties tab, look for the key "Duration" and the value should be "1: 35,637 (4,590,592 samples)."
In the Metadata tab, look for "LoopEnd" and "LoopStart" keys.
Values should be "4586496" and "316928". These values are also samples.
RE5 uses the "samples" to define the points song length, loop start and end of the loop.
The definitions file background music can be found here:
CoreResource.arc \ sound \ bgm \ st_bgm.stq
You will need to extract and repackage this file CoreResource.arc using the Arc tool.
You will need a hex editor to edit the file st_bgm.stq.
St_bgm.stq open with HxD hex editor. Press CTRL + F and select "integer" for the type of data and research to 4,590,592, which is the length of song samples. You should reach 44C offset by 4 bytes 00 46 00 0C.
The sample values herein will reverse hexadecimal and 4 bytes in length.
460C00 hex decimal = 4590592 = 00 0C 46 00 hexadecimal reverse
44C Offset: 00 0C 46 00 DURATION = SONG
450 Displacement: 4 bytes of mystery!
454 Displacement: 00 04 00 D6 = LoopStart
458 Displacement: 00 FC 45 00 = LoopEnd
You just edit the byte offsets these with the values of samples of new music that you will use and then the music will circulate properly. Remember the bytes must be hexadecimal otherwise!
I recommend that new song you use to be in lossless format like WAV or FLAC, before converting it to OGG using Audacity. Converting OGG to MP3 × can result in poor sound quality! When exporting to OGG, I use six quality to achieve nominal bit rate 192 which is the same as the music files RE5.
If you do not want to loop music in ogg / sngw file under the Metadata tab, and change the LoopEnd LoopStart values for both -1. Then in stq file, change the bytes to LoopEnd and LoopStart both FF FF FF FF. I replaced the song "You're dead" using this method, because I only wanted to play once.