cseq2mid by kr3nshaw at 10:00 PM EDT on May 30, 2018
My search for the sequences used in the StreetPass minigames led me to this post. The person who uploaded the archive also included cseq2midi by soneek, but the version provided doesn't convert the sequences properly.
Using the source code of soneek's program (also provided in the archive), I rewrote cseq2mid from scratch. My version is capable of converting all of the musical sequences without fail.
The program struggles to convert ambient sequences, due to the usage of arithmetic operations and multiple subroutines. If there's anybody who understands more about this than I do, please look at the source code on GitHub and tell me which commands I haven't implemented properly.
The next step is to work out how to create SF2 or DLS files from the data in the StreetPass BCSAR, as some of the sequences sound a bit odd when played back using GM. I haven't been able to find a tool that does this yet. Does anyone know of such a program?
If you're curious about the bits of the format you have listed as unknown, check out this bcseq 'decompiler' I threw together. I posted this in the 3DS thread like two and a half years ago, but it looks like the original link is down.
Hey kr3n, it's me from the Discord, figured this would be the best place to point you to this: https://drive.google.com/open?id=0B2lMV7NovfEOZWt1QTE1ZEp5d0E This has the .BCSARs from the games added in 2017 and I think they deserve a look see just as much as the other ones.
Does anyone know how to convert this NA_BGM_FIELD.cseq file to MIDI? This file is extracted from oot3d using caesar.I haven't found a tool that can be converted.
If you decompile the cseq with the python script I posted on the last page you'll see that it's not a simple music track. https://pastebin.com/peY2hCxS It's checking and setting variables and such. Not really something that can be easily translated to midi.
My script isn't fully decompiling this cseq due to oversight on my part. cba to fix it, tbh. Add "self.labelFromOffset(0, 'loc')" after line 51 as a band-aid.
Whoa, thanks so much for this. Works great on KK Slider's songs; I've been looking for tools that could properly convert *cseq > mid for years--suffice it to say the original program didn't do a thing.
A bit off-topic, of course, but my goal is to eventually go backwards (ie have KK sing what I tell him to). I assume the only way to do this is via SDK tools?
This wiki page (which is from August 2018 at the earliest) seems to proclaim that such a converter exists, though no link is provided, nor is one publicly available. Aside from that, I'm not aware of any tools that can convert them or are being worked on to convert them, even in the SDK (though to be fair I have no idea what actually is in the SDK, if someone wants to fill in the blanks please do). Even if you had one, unless you like aimless hex editing you can't put it into the game, since there is no (publicly) known way to decompile/edit a BCSAR, something the SDK definitely cannot do. I've looked into it for a bit, but haven't really been sure how to approach it.
I'm not at all familiar with the music world's jargon, so it might be better if I explained.
I was able to extract a thousand or so of CWAV files from a BCSAR. After converting them to WAV, I found out that they are "pieces" of the actual songs from the game.
If I got this correctly, the CSEQ files, after being converted to MIDI, will allow me to listen to the game music as it was meant to be, especially because there are references to "BGM" inside the BCSAR.
I would like to know how to go about feeding that MIDI and those WAVs to a program, and get some actual music back. My environment is Debian Stretch, but I can fire up Windows 7 if needed.
Uh........then you would just use caesar (or anything that can turn the .CBNK and .CWAR into a SoundFont, not that any other program exists for that purpose anyway), load the sequence and SoundFont in your DAW of choice, and play it back.....It's the same as any other format with SoundFonts and sequences really.
I know next to nothing about Debian so I can't help you on that front unfortunately.
I felt this was most appropriate for this thread: I did some digging and there does seem in fact to be an official tool for converting sequences. Unfortunately (or perhaps fortunately....), no information about it seems to exist anywhere on the net, not even a name; the only reason I even know about it is that I heard it via word of mouth.
If it's anything like the DS's equivalent, then this should allow conversion to .CBNK and .CWAR as well.
caesar source code by icecream at 12:05 AM EDT on March 28, 2019
Thought I'd let everyone (who cares) know: the source code for caesar is now on github: https://github.com/kr3nshaw/caesar Assume all binaries available currently are out of date.
I've talked to a few people interested in it and while we all agree that the 3DS needs an equivalent of either "sf" or Nitro Studio (since the playback would be accurate to the console), we have no idea where to even begin. We'd essentially have to program a sound system and none of us have the knowledge or skills to do so. Even Gota7, the author of Citric Composer (who also made Nitro Studio), isn't sure how to approach it. I've spoken to Kermalis about adding compatibility with VG Music Studio, but that's a long shot.
If you know someone that is interested in this and has the skills to do so (preferably someone who has written an *sf format), please let us know.
edited 12:37 PM EDT August 31, 2019
starters by MDHEXT at 11:02 PM EDT on September 14, 2019
for starters, we should begin to examine the 2sf, and gsf formats. these are capable of re-creating different effects for the music they contain. i'd recommend creating a format that doesn't just work for bcsar files, but also their Wii and WiiU variants. stepping back and seeing what all these formats have in common, as well as looking to the structure of other sf formats, will allow us to create a format that is versatile and useful to rippers. i think that the first step should be to map out the file structure of the brsar, bcsar, and bfsar formats. after that, we can begin looking for ways to create a new sf extension based off of the newly acquired knowledge. this thread is now the homebase for the development of this new sf format.
I completely agree that the best starting point are the existing *sf formats for other Nintendo consoles. What I meant though was more along the lines of "none of the people I've spoken to know how to read the *sf code", and the people that can haven't expressed any interest yet (again except maybe Kermalis, and since he isn't specifically focusing on B*SAR it's a bit of a shot in the dark). I know there's interest, especially for the Wii U sequences, but no one seems to be committed into actually making it happen. I'd try myself, but I am no programmer. :p
i'm guessing that the external groups are an issue. extracting the bcsar using my fork of these tools shows that there are some external groups that can't be accounted for. these are just my thoughts tho.