Author Topic: Some soundfonts' sample mappings are suddenly broken?  (Read 421 times)

Offline foxley

  • Shy artist
  • Posts: 2
Some soundfonts' sample mappings are suddenly broken?
« on: August 25, 2020, 02:04:42 »
I updated to the latest version of OpenMPT recently and just noticed that several instruments in the Fluid R3 SF2 soundfont have broken sample mappings. For example, when importing the soundfont's first instrument (Yamaha Grand Piano) to an OpenMPT instrument, it imports 20 samples and almost all notes are mapped to sample 21, which is empty. Normally it has 2-3 samples per octave and maps them properly to note ranges.

I tried using this same SF2 that I've been using for years in sforzando and it works there, so that rules out some inexplicable corruption to the soundfont (also its date modified property has not changed).  I'm thinking something may have changed with the way soundfont patches get imported to OpenMPT instruments and now it isn't playing nice with some soundfonts... also this isn't happening to every instrument in the Fluid R3 soundfont, but several, which isn't good because I'm missing a lot of potentially useful instruments now.

Has anyone else been running into this problem with soundfonts?

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #1 on: August 25, 2020, 02:22:33 »
I join.
After updating till 1.29.02 I already asked this question on Issue Tracker. Also received the answer about the structure of multi-layered instruments of the making SF2. Because of my incompetence I did not begin to argue, but was not satisfied with the answer.
Really, many instruments SF2 began to be imported in a different way (and often not to the best).

P.S.
I want to specify that for the first time found this failure later after correction on subject number 0001336 in Issue Tracker.
« Last Edit: August 25, 2020, 08:25:35 by Alex TEHb »

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 7,093
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 10 x64
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #2 on: August 25, 2020, 10:45:48 »
There was indeed an issue since OpenMPT 1.29.01.00 with instruments that have many key zones and instrument layers at the same time, leading to an incomplete import of the key zones. r13486 should fix this, soon available from https://builds.openmpt.org/builds/

Quote
Really, many instruments SF2 began to be imported in a different way (and often not to the best).
There were several issues you reported - issue 1336 was already fixed, but the fact that sometimes samples are imported without being associated to the instrument is fully intentional, as explained in the other issue you opened. To re-iterate, OpenMPT now tries to import all samples from all instrument layers, even if only one layer per key can be assigned to an instrument. This leaves you the choice to either delete those samples, or create more instruments for the other layers.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #3 on: August 25, 2020, 11:07:50 »
1336 - corrected! Thank you!
In subject 1338 I tried to explain that before when importing instrument I received 10 samles INVOLVED, and after correction of 1336 in the same instrument remained only 3 (!!!) involved and 7 uninvolved.
I know nothing about multi-layers and your answer did not understand. Also came to a conclusion that and it was conceived... :). Therefore decided not to continue a subject not to bring new mistakes because of not correctness of the translator... :)

I thank for responsiveness and the attentive attitude towards users!

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 7,093
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 10 x64
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #4 on: August 25, 2020, 11:15:51 »
I know nothing about multi-layers and your answer did not understand.
Simply put: Imagine you have a piano soundfont instrument which is arranged like this:

Sample 1: C-4 to B-4
Sample 2: C-5 to B-5
Sample 3: C-6 to B-6

OpenMPT always imported this correctly with three samples.

Now imagine a more complicated piano instrument like this:

Sample 1: C-4 to B-4, playing at volume 0 to 31 (soft hit)
Sample 2: C-5 to B-5, playing at volume 0 to 31 (soft hit)
Sample 3: C-6 to B-6, playing at volume 0 to 31 (soft hit)
Sample 4: C-4 to B-4, playing at volume 32 to 64 (hard hit)
Sample 5: C-5 to B-5, playing at volume 32 to 64 (hard hit)
Sample 6: C-6 to B-6, playing at volume 32 to 64 (hard hit)

As OpenMPT can only import one sample per note it previously imported just the "hard hit" (or "soft hit", depending on which order they appear in the file) samples and ignore the "soft hit" samples. If you wanted to use them, you couldn't do it without resorting to external tools liek Viena.
Now with OpenMPT 1.29, all six samples will be imported, but the "soft hit" samples will not be associated with any instrument. You have the chance to set up your own instrument to use them without using a tool like Viena, or you can simply delete them.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #5 on: August 25, 2020, 11:30:33 »
I thank for an explanation.
I met it in VSTi. There I manually chose "strong" samples for instrument taking into account that they can always be lowered.
And ignored "weak" samples since their increase requires separate Sound Editor, or at least the Normalize function...
If to take both that and others in one tracker instrument, nothing will turn out!

You already wrote that at "silent" samles the compression of FLAC is better, but in my opinion they are less effective in songs...

The question arises:
Whether it is possible to turn off import of nezedeystvovanny samles? Not completely, and as necessary? (Separate tick).
I think, it should be discussed when we are able to test r13486...
« Last Edit: August 25, 2020, 11:46:16 by Alex TEHb »

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #6 on: August 25, 2020, 13:00:48 »
Tested r13486 on 5 soundfonts. Of course, it is not an indicator, but there are no remarks!

Can be to eat sense to organize poll of users?

When importing multi-layers instrument from SF2 you want to receive:
a) only "strong" samles
b) to have all samles. I will choose necessary, and unnecessary I will remove manually
c) only "weak" samles

-----------------
I have not such wide experience. Whether there are situations that instrument contains not all scale "strong" and "weak", and is supplemented partially with any given?

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 7,093
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 10 x64
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #7 on: August 25, 2020, 16:10:35 »
Asking the user for each instrument what to do will be extremely annoying. I will not do that. The only correct way to solve this would be to support multi-layered instruments, but that's a lot of work so it will probably not happen anytime soon.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #8 on: August 26, 2020, 03:40:37 »
Whether it is possible to mark not used samples as inactive? (Fonts, Colour)
Then there is no need to do full cleaning for the song.
« Last Edit: August 26, 2020, 11:30:36 by Alex TEHb »

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 7,093
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 10 x64
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #9 on: August 26, 2020, 10:35:51 »
I think I cannot understand that question.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.

Offline Alex TEHb

  • Inspired artist
  • **
  • Posts: 66
  • Gender: Male
  • Operating System: Win7 x86
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #10 on: August 26, 2020, 11:26:57 »
Let's say I want to replace in a ready melody of Horn with Flute.
I play pattern and on the run I substitute the Flutes in turn instead of Horn at once to understand as far as with other tools new instrument is in consonance.
I have 20 Flute in SF2. I ALL tried them.
How many after that unnecessary samples in the module?!!

Having made CleanUp, I will remove also them, and samples of OTHER instruments.
And it is not necessary to me!

Of course, it is possible to load the module in a new way and to insert only one new chosen instrument. Then to come into it and to manually calculate and remove unused samples.

In this case to store instrumets in SF2 format becomes silly because of complexity of their application... :(



Uf-f-f-f! Even was tired to describe it. And why so to complicate everything?
« Last Edit: August 26, 2020, 11:49:03 by Alex TEHb »

Offline Saga Musix

  • OpenMPT Developers
  • *****
  • Posts: 7,093
  • aka Jojo
    • Download music, samples, VST plugins: Saga Musix Website
  • Operating System: Windows 10 x64
Re: Some soundfonts' sample mappings are suddenly broken?
« Reply #11 on: August 26, 2020, 13:12:08 »
Quote
Having made CleanUp, I will remove also them, and samples of OTHER instruments.
And it is not necessary to me!

OpenMPT asks you if you want to do that. It will say something like "OpenMPT detected 14 samples referenced by an instrument, but not used in the song. Do you want to remove them?". If you answer "no" to that question, only completely unused samples are removed, and samples associated with any instrument will not be modified.
» No support, bug reports, feature requests via private messages - they will not be answered. Use the forums and the issue tracker so that everyone can benefit from your post.