Previous Page

by orangeisbetter at 11:52 PM EDT on September 17, 2023
I'm just popping in on this subject, as I've been really into this whole music thing for a little while now. I tried using the php code to convert .bms to .midi, but it doesn't seem to work. Has anyone else run into this problem? It could be my php configuration, but I don't know
BMS Converter by hat at 12:03 PM EDT on October 7, 2023
I managed to whip this together in a week a few months ago. You can use Yuuto's mostly working soundfont, but this can convert the BMS's with reasonable accuracy.

Github Link

There is some clunkyness with pitch's in some songs, but it's a big improvement from the old converters. In truth though, the MIDI format itself is so limiting; would be much more useful if someone had a sequencer / live-player instead that supports all of J2A's systems for 1:1 pure audio.

Zant's theme is a great example as it uses PPQN changes which MIDI doesn't support. It still works don't get me wrong, but it isn't a 1:1 conversion for a couple of the songs and I doubt it'll ever be due to MIDI limitations.

Some people have used it for other similar games that use the J2 audio system (Super Mario Galaxy) and it seems to work fine.

This version should correct the broken pitch bends that the old VGM-Trans fork used. Either way it was about time that we moved away from the old php converter. So hopefully this helps!
Live BMS player in the making by Yuuto2 at 12:01 PM EDT on October 8, 2023
You are correct @hat, a live player would be really helpful. As you already pointed out, MIDI and also SF2 are quite limiting and thus not really suitable for ripping music and sound effects in this case.

That is why I have been working on a live player/renderer for quite some time now. It aims to mimic the JAudio system (currently only exactly the version Twilight Princess uses) as closely as possible. For the unknown stuff I am reverse-engineering the game's code in a disassembler/decompiler, which is a very tedious task and consumes a lot of time.

I also used this live-playing approach to render BMS to MIDI earlier this year and it could already handle most of the dynamic commands, see here. That thing was just a proof of concept that converted BMS to MIDI live and passed the MIDI events and the pre-generated soundfont to a MIDI renderer to play it back (with all limitations, that is).

I'm really sorry it takes so long, but this is my all-time favorite long-term project and I have high standards regarding my work on that. Also, I switched from C++ to Rust mid-progress because I wanted to learn that language anyway.

TL;DR: BMS live player/renderer (TP version) in progress, there is steady but slow progress, time is scarce and I cannot make a guarantee for a finishing date.
by Yuuto2 at 12:10 PM EDT on October 8, 2023
If you really want to see the state of the "old" C++ POC I abandoned, I perhaps can find some time to make the project a bit more portable and usable and eventually upload that code.
Twilight Princess BMS player preview by Yuuto2 at 4:30 PM EST on February 20, 2024
I spend a lot of time on trying to implement a live BMS player recently and got quite some work done. I am now able to playback TP's music sequences in realtime with an output already close to the original.

See for yourself with this little command line tool I've hacked together. In order to be able to use it, you need to extract the "Audiores" folder (which includes the Wave folder) and .bms files from the game ROM. Then run the following in a command prompt:

bmsplay.exe --path <path to Audiores folder> --bms <path to sequence> play

So for me it could be: bmsplay.exe --path "C:\Users\yuuto\TP\Audiores" --bms "C:\Users\yuuto\TP\Audiores\Seqs\seqs\deathmountain01.bms" play

When playing back an interactive sequence that contains segment jumps (like most of the boss themes do), you can enter the segment number you wish to jump to in the console. E. g. when playing e_fireman and entering 1, the "vulnerable" part is played. When entering 2, you jump back to the main track. Feel free to experiment.

Bonus: Instead of "play" you can pass "render" together with an output filename to render 2 minutes of a sequence into a wave file.

Example:
"C:\Users\yuuto\TP\Audiores" --bms "C:\Users\yuuto\TP\Audiores\Seqs\seqs\deathmountain01.bms" render --out "C:\Users\yuuto\Desktop\deathmountain01.wav"

Please keep in mind that at the moment this tool is just for testing purposes. Thus it's not very convenient to use, largely untested on other systems except for my very own and may break any time. The executable is Windows-x64-only but the project itself is cross-platform. It is still under heavy development and it may take a while to produce stable results.

That being said, here's a short summary of what works what doesn't:
- Envelopes are fully supported.
- Support for surround sound is built-in, but the tool uses a stereo mixer in the last step. But there will be 5.1 mixing in the future.
- Most features are implemented in a way that mimic the original very closely.
- Reverb however is emulated very roughly.
- On segment jumps, all releasing notes are cut off.
- Tremolo & vibrato work. See e_goma02 and e_zant (segment 8/9).
- Support for some BMS commands and more advanced sound registers is still missing, but most of these are only used by the SFX sequences.
- There are still some sound artifacts like crackling or sudden volume changes.

There is still a lot to and a lot of details left to implement, but I think this is a solid foundation and implementing this has definitely been a lot of fun.

edited 4:32 PM EST February 20, 2024
by Mouser X at 11:29 PM EST on February 21, 2024
This is awesome! I really hope to see the work on this continue! I'd love to have the ability to listen to native Gamecube sequences on the PC, rather than recordings! I really hope this leads to other, previously unripped games, becoming available (Skies of Arcadia: Legends, for example, or Four swords on the Gamecube, or maybe Final Fantasy: Crystal Chronicles...). Though, unfortunately, it *does* require that the game in question is using the Nintendo dev kit for its audio, so obviously, this still leaves a lot of games as unavailable.
by hat at 11:28 PM EST on February 25, 2024
Super awesome @Yuuto2! I think we've definitely come to the consensus that live players are definitely the way to go, must've opened up a lot of freedom not being constricted to MIDI and soundfonts.

Love how e_zant actually now works with PPQN changes, and the howling tracks function. Theres a few expected audio artifacts (snowboard has some crackles).
Hopefully it'll get some more features like individually exporting the sub-tracks and changing their volumes (like in holy_forest where everything is combined but changed in-game through triggers). Either way, some massive progress!
by Yuuto2 at 7:43 PM EST on February 26, 2024
You're totally right, the MIDI+SF2 method has been way too limiting. On the other hand, this freedom requires a complex implementation, but in my opinion this is totally worth it.

None of the tracks have a PPQN change, as far as I can tell. Ticks per beat is set to const. 120 at the beginning of the root track for each music sequence. Maybe you mean tempo changes? e_zant has some of them.

One of the next things I will implement is volume ramping which should eliminate most audio artifacts.
Next step is to add support for playing back sound effects. After that, enabling/disabling and volume control of single tracks will be next. I think creating a convenient tool that actually offers some useful settings for playing/rendering would also be a great idea. Oh and getting all this stuff on GitHub.
by a574045075 at 7:31 AM EST on November 7, 2024
@Yuuto2 Hello! What tools extract SF2 from Z2Sound.baa?

Previous Page
Go to Page 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Search this thread

Show all threads

Reply to this thread:

User Name Tags:

bold: [b]bold[/b]
italics: [i]italics[/i]
emphasis: [em]emphasis[/em]
underline: [u]underline[/u]
small: [small]small[/small]
Link: [url=http://www.google.com]Link[/url]

[img=https://www.hcs64.com/images/mm1.png]
Password
Subject
Message

HCS Forum Index
Halley's Comet Software
forum source