Falcosoft wrote on 2024-08-05, 13:45:Hi,
1. You should simply overwrite midiplayer.exe in the existing MidiPlayer6 folder with the new test exe file. But make sure […]
Show full quote
Spesek wrote on 2024-08-05, 12:59:Hi again Falco,
I can't get the FSMP 6.5 to work.
The test zip you've provided only contains the executable. It said that the ba […]
Show full quote
Falcosoft wrote on 2024-08-05, 00:12:Thanks! […]
Show full quote
Thanks!
As I said in the previous post this is not 100% true since SF2Pack is not restricted to ogg/vorbis compression but also supports lossless codecs like FLAC or WavPack.
BTW, here is an FSMP test version that already supports the 'DBNK' chunk for both reading and writing:
https://falcosoft.hu/midiplayer_65_test.zip
In Event Viewer/Debugger dialog's 'File menu -> Save File As' you should select 'Riff Midi + Embedded SF2' type. Then after you have set the rmidi file name it asks for a 'Destination bank for SF2 soundfont'. You can select a value between 0-127. If you press Cancel in this dialog the 'DBNK' chunk is NOT saved into the the rmi file else the given value is saved. Finally you have to select the soundfont to be embedded.
The attachment rmi1.png is no longer available
The attachment rmi2.png is no longer available
Hi again Falco,
I can't get the FSMP 6.5 to work.
The test zip you've provided only contains the executable. It said that the bass.dll is missing so i copied it from FSMP 6.4 there but it still doesn't work:
The attachment no_bass.png is no longer available
Let me know what should I do to make it work.
PS: I understand that SFPack is not restricted to ogg, but sf3 isn't either. But even then, it won't be as easy for me to implement other codecs:
The JavaScript problem
You see, normal executables such as BASS or fluidsynth can essentially tell the system to decode stuff for them. For example, fluidsynth calls "libsndfile" which uses the system's ogg vorbis decoder to decode the sample.
And it would be relatively easy to add support for other compression types. Unfortunately, it's not that easy for javascript, which spessa runs on.
This is the vorbis decoder for spessasynth. It is essentially C recompiled to javascript.
The encoder is even larger, weighing 1.5MB(!) which is very large for a minified text file. If I wanted to add another encoder or decoder, that means yet another huge file with the code.
There's also another concern:
The standard problem
The most supported sf standard is the stock sf2 standard. Then there's sf3, which is also supported by all major players (Fluid which means VLC, BASS which means FSMP6 and VirtualMIDISynth, musescore, timidity++)
These two standards have proper documentation. SF2 has the sfspec and SF3 has the wiki page on fluidsynth.
Then there are proprietary standards:
SynthFont's SoundFontKomPressd. Quote from the page:
This is the first program on the market that can use the new proprietary SoundFont format “SFKR” (“SoundFont KompRessd”) designed and developed by SynthFont in collaboration with GoldMidiSF2.
Sfpack. There's no specification and it's only supported by BASS. Looking at the standard, it seems that it's essentially SF3: compressed samples.
SF4: FLAC compression
What I'm trying to say is There are many non-standard soundfont standards, which effectively achieve exactly what SF3 does. Why not focus on the widely supported (and somewhat standardized) SF3 and expand upon it.
I'm not saying that SF2Pack is bad in any way, I just think it is a little unnecessary. I'll still add 'sfpk' as a valid soundfont chunk type in the spec if you want, though.
Relevant xkcd:

Wow, that was a long post scriptum.
Hi,
1. You should simply overwrite midiplayer.exe in the existing MidiPlayer6 folder with the new test exe file. But make sure that if you downloaded the 32-bit version of MidiPlayer 6.4 then copy the new executable from the x86 folder and if you downloaded the 64-bit version then copy the new exe from the x64 folder.
The error on your screenshot can be reproduced exactly if you use the exe with the wrong bitness 😀
2. OK, I have understood and I partly agree. I have just mentioned that 'sfpk' support exists in my code (that is the 1st implementation of the standard 😀 )
Alright, that works! I've extracted the x64 version but the dlls were for x86. My bad 😀
Here are some of my tests:
The good
Works great! Bank 0, 1, 2 5 all work fine! Also an XG multi-drum midi with bank 0 works fine which is also great!
One problem: it straight up ignores the name (INAM). The shift_jis kanji test I've made was exactly for this. The IENC uses "Shift_JIS" encoding and the INAM is encoded as such. It should display "恋色マジック from 東方萃夢想" but it displays the file name.
Other than that small thing, it works great.
Can't say that about saving though.
The bad
First, the format is saved as .mid instead of .rmi. But this is a minor issue.
Second, the soundfont just gets copied into the file which results in this:
The attachment ohgod.png is no longer available
SpessaSynth trims it to only use the samples in the MIDI. (It finds every key-velocity combo for each used program (on each track and each port if multiport) and removes every unused preset and every unused sample in the used presets)
Third, the banks are not shifted. I've specified an offset of 2 and put a gm midi in, and it also was copied without change. This results in fsmp6 using the main bank instead of the embedded one.
Spessa does alter the bank selects for the offset (it doesn't just blidnly add offset though. It checks if the preset exists in the given soundfont then adds offset to it. For example original calls 50:16 because it was made for some specific soundfont. spessa then checks for this preset. Let's say that the only preset with program 16 is 0:16. So it adds offset to that which for offset of 2 becomes bank select 2 and program 16. Same with programs, except for adding the offset)
Lastly, spessa just... doesn't see the embedded soundfont from files exported by fsmp6, like, at all. But that might be spessa's issue, not yours because fsmp6 detects it fine. I'll look into it.
PS: I also have a feature request: can you allow me to go past channel 16 in the GUI for multi port midis? Currently it's not possible.