Creating a soundfont... how many velocities?
-
- KVRist
- 211 posts since 27 Feb, 2005
Hello,
I am planning on creating some soundfonts. What velocity values should I be sampling? What are the most popular velocities soundfont designers use? Multiples of 16, maybe?
The backstory: I just found out about the Csound DX7 Patch Translator
http://www.parnasse.com/dx72csnd.shtml
which takes a DX7 bank and generates a bunch of CSound files, one per patch.
Which means that in theory one could write a little script that takes a DX7 bank and generates all the required WAV's for a soundfont. That is, for all patches in the bank, generate one WAV per note, at different velocities.
So, I was planning on taking some of the myriad DX7 patches floating around the 'Net and create some soundfonts from them. Just give the patch to the program and instruct it to generate one WAV per note for a set of notes at different velocities.
I was thinking 3 or 4 notes per octave, but not sure about what velocities to use. Any recommendations are welcome.
Thanks in advance
The L
I am planning on creating some soundfonts. What velocity values should I be sampling? What are the most popular velocities soundfont designers use? Multiples of 16, maybe?
The backstory: I just found out about the Csound DX7 Patch Translator
http://www.parnasse.com/dx72csnd.shtml
which takes a DX7 bank and generates a bunch of CSound files, one per patch.
Which means that in theory one could write a little script that takes a DX7 bank and generates all the required WAV's for a soundfont. That is, for all patches in the bank, generate one WAV per note, at different velocities.
So, I was planning on taking some of the myriad DX7 patches floating around the 'Net and create some soundfonts from them. Just give the patch to the program and instruct it to generate one WAV per note for a set of notes at different velocities.
I was thinking 3 or 4 notes per octave, but not sure about what velocities to use. Any recommendations are welcome.
Thanks in advance
The L
-
- KVRAF
- 3139 posts since 6 Sep, 2002 from United Kingdom & Opinions Will Travel :O)
If you had programmed the patch – you would know – its generally not cool to copy sound designers patches straight in that way.
Re- velocity – there are no fixed rules – it depends if the sound needs velocity changes. Real and expressive instruments like the piano would have the need for many many velocity layers as the string would resonate differently at each setting and if done in stereo, this same string can influence those strings around it as the velocity increases – same for drums etc. so the more the better in these multi mic set-ups.
If its just one sound with one velocity and one mic, its more likely you would only need the one sample taking care of 0-127, unless you were wanting to layer in subtle variations at different velocities to give more life to the sound.
Best regards,
Spe3d
:O)
Re- velocity – there are no fixed rules – it depends if the sound needs velocity changes. Real and expressive instruments like the piano would have the need for many many velocity layers as the string would resonate differently at each setting and if done in stereo, this same string can influence those strings around it as the velocity increases – same for drums etc. so the more the better in these multi mic set-ups.
If its just one sound with one velocity and one mic, its more likely you would only need the one sample taking care of 0-127, unless you were wanting to layer in subtle variations at different velocities to give more life to the sound.
Best regards,
Spe3d
:O)
-
- KVRist
- Topic Starter
- 211 posts since 27 Feb, 2005
It's just for personal use, not to resell or anything, sorry if I wasn't clear. There are truckloads of what seem to be freeware patches floating around.Spe3D wrote:If you had programmed the patch – you would know – its generally not cool to copy sound designers patches straight in that way.
It would be the equivalent of downloading a patch from the net into my DX7 (if I had one) and playing it on a song, I guess. Only instead of a loading the patches into a piece of hardware I would convert them to soundfonts and play them with a soundfont player. I guess you can do the same (more expensively) with FM7.
Thanks for the ideas about velocity. I think I'll generate waves for velocities 16, 32, 48... 127 and see which ones make a difference.
Best,
L
-
- KVRAF
- 2844 posts since 1 Jan, 2003
Listen to Spe3D, he's the man.
It really depends on the instrument. When I first sampled my accordian, I sampled every fourth note at two velocity levels. Stretching the samples accross the keyboard sounded very bad (the natural tremolo in the accordian caused strange unnatural beating when chords were played). It was a better use of MBs, and sounded better, to use one velocity layer but sample every note and not create loop points, but let the notes decay in that wheezing way accordians do. This sounded much better because accordians are not extremely velocity sensitive anyway. Virtuoso accordian players can flame me here.
It really depends on the instrument. When I first sampled my accordian, I sampled every fourth note at two velocity levels. Stretching the samples accross the keyboard sounded very bad (the natural tremolo in the accordian caused strange unnatural beating when chords were played). It was a better use of MBs, and sounded better, to use one velocity layer but sample every note and not create loop points, but let the notes decay in that wheezing way accordians do. This sounded much better because accordians are not extremely velocity sensitive anyway. Virtuoso accordian players can flame me here.
-
- KVRAF
- 13444 posts since 14 Nov, 2000 from Hannover / Germany
A majorly important thing on the decision about the amount of velocity (and partially key-) mappings is whether you'd be able to reproduce certain things from the original sound with the sampler you're going to use.
Example: You have some FM E-Piano sound (as you were talking about the DX-7). Now, let's assume there's no effect on it (sometimes some LFO-ing might be going on, but let's forget about that for a while).
Now, when you play this patch on an original DX-7 (or maybe on NIs FM7) you may most likely notice that the only thing happening will be that it get's a tad more dull at lower velocities - and probably not even that as the DX7 had no filter.
Perhaps FM intensity will be controlled via velocity too, resulting in such an effect.
While you won't be able to reproduce that effect 100% realistically on a sampler (especially in case FM intensity is controlled via velocity), you might get close by controlling a filter's cutoff via velocity. Obviously, your sampler of choice needs a filter which can be controlled via velocity then.
Another trick would be to modulate sample start points via velocity (again, your sampler needs to support this). You'd be cutting away the sharp attacks of your samples on lower velocities.
A similar effect can be achieved by controlling attack time via velocity. Lower velocities in this case would slightly raise attack time - a very slight amount usually is good enough, especially when using the other two modulations mentioned as well.
Using those techniques I found myself being able to do pretty much convincing patches of a bunch of source sounds without having to layer too much samples - very often I even only use one layer, the source samples being recorded at maximum velocity (which usually means the brightest sound).
All modern samplers (EXS24, Kontakt, HALion, Mach 5, Shortcircuit, VSampler...) support such techniques.
Of course, if you're indeed planning to stick with the SF2 format, you'll be somewhat limited.
Things are obviously getting more critical for "real" instruments when the actual overtone structure and resonance will change at different playing levels. These are tough to be reproduced with your sampler's onboard functions. Time to sample more velocity zones.
But then, this is where the work starts - and I mean serious work.
As soon as you're using velocity mappings, you may notice the sample switching when playing your sampled patch.
There's two solutions to this, both introducing new troubles:
- More velocity zones. For truly realistic representations you may need up to 8-10 zones per key. Some modern sample libraries are even using more. => WAY more work.
- Velocity crossfading between zones. In that case the zones will blend into each other around the velocity switching point. The critical thing here being that phase errors may occur in the overlapping area (especially true for all sorts of natural instruments). It might work fine for some electronic sounds though. Of course your sampler of choice has to support velocity x-fading.
Even if you only asked for velocity mppings, things get even more difficult if the source patch has some modulations going on, let's say a smooth vibrato for instance.
Now, most likely this vibrato will sound the same all over the keyboard range, but when you sample one note and let your sampler do the pitching job, the vibrato will be pitched too - something you defenitely don't want. So you'd need a LOT of keyboard zones for such patches.
This can sometimes be ommited by switching off the effect on the source module/instrument. Of course you will have to have access to it. You could then try to reproduce the (in this case vibrato) effect in your sampler of choice.
It can't however be ommited in case theres some modulations going on which are vital to the source patches basic sound, such as any sort of pulsewidth modulation, or, in case of the DX7, FM intensity modulation.
In that case you will again need WAY more samples mapped throughout the playing range.
Anyways, my personal receipe would be:
- Carefully listen to the source patch (if possible of course) and decide WHICH are the important parameters you'd like to be represented in your sampler patch. In case of a typical DX-7 E-Piano it might not be all that much, you just want that bell-ish, sometimes a bit hollow character. In this case anything else (such as the mentioned tremolo) can be reproduced on your sampler of choice.
- Depending on the original patches behaviour, decide whether you need much velocity zones or whether you could recreate things more easily on your sampler (such as using the aforementioned velocity to cutoff/attack/sample start modulations).
- Depending on the patches source sound quality, decide whether you need a few or many key zones. As said, many FX (such as simple pitch or volume LFOs) can be recreated easily on almost every sampler, no need to sample these.
Final note about key mappings: Even if you only sampled a very simple signal, such as a sine wave patch, which will just sound the same all throughout the keyboard (apart from changing pitch), it will most likely still be a good idea to sample at least each octave (personally I'm using at least tritones). In case you'll be using less keyzones, the sampler will have to do all the pitching work which a) will result in more CPU useage and b) might result in some aliasing artefacts, depending on the internal sampler engine. And then, in case the sampler has a very high quality internal engine (such as found in sfz(+) or ShortCircuit), this also comes at a cost. More keyzones will use up less CPU power in any case.
Example: You have some FM E-Piano sound (as you were talking about the DX-7). Now, let's assume there's no effect on it (sometimes some LFO-ing might be going on, but let's forget about that for a while).
Now, when you play this patch on an original DX-7 (or maybe on NIs FM7) you may most likely notice that the only thing happening will be that it get's a tad more dull at lower velocities - and probably not even that as the DX7 had no filter.
Perhaps FM intensity will be controlled via velocity too, resulting in such an effect.
While you won't be able to reproduce that effect 100% realistically on a sampler (especially in case FM intensity is controlled via velocity), you might get close by controlling a filter's cutoff via velocity. Obviously, your sampler of choice needs a filter which can be controlled via velocity then.
Another trick would be to modulate sample start points via velocity (again, your sampler needs to support this). You'd be cutting away the sharp attacks of your samples on lower velocities.
A similar effect can be achieved by controlling attack time via velocity. Lower velocities in this case would slightly raise attack time - a very slight amount usually is good enough, especially when using the other two modulations mentioned as well.
Using those techniques I found myself being able to do pretty much convincing patches of a bunch of source sounds without having to layer too much samples - very often I even only use one layer, the source samples being recorded at maximum velocity (which usually means the brightest sound).
All modern samplers (EXS24, Kontakt, HALion, Mach 5, Shortcircuit, VSampler...) support such techniques.
Of course, if you're indeed planning to stick with the SF2 format, you'll be somewhat limited.
Things are obviously getting more critical for "real" instruments when the actual overtone structure and resonance will change at different playing levels. These are tough to be reproduced with your sampler's onboard functions. Time to sample more velocity zones.
But then, this is where the work starts - and I mean serious work.
As soon as you're using velocity mappings, you may notice the sample switching when playing your sampled patch.
There's two solutions to this, both introducing new troubles:
- More velocity zones. For truly realistic representations you may need up to 8-10 zones per key. Some modern sample libraries are even using more. => WAY more work.
- Velocity crossfading between zones. In that case the zones will blend into each other around the velocity switching point. The critical thing here being that phase errors may occur in the overlapping area (especially true for all sorts of natural instruments). It might work fine for some electronic sounds though. Of course your sampler of choice has to support velocity x-fading.
Even if you only asked for velocity mppings, things get even more difficult if the source patch has some modulations going on, let's say a smooth vibrato for instance.
Now, most likely this vibrato will sound the same all over the keyboard range, but when you sample one note and let your sampler do the pitching job, the vibrato will be pitched too - something you defenitely don't want. So you'd need a LOT of keyboard zones for such patches.
This can sometimes be ommited by switching off the effect on the source module/instrument. Of course you will have to have access to it. You could then try to reproduce the (in this case vibrato) effect in your sampler of choice.
It can't however be ommited in case theres some modulations going on which are vital to the source patches basic sound, such as any sort of pulsewidth modulation, or, in case of the DX7, FM intensity modulation.
In that case you will again need WAY more samples mapped throughout the playing range.
Anyways, my personal receipe would be:
- Carefully listen to the source patch (if possible of course) and decide WHICH are the important parameters you'd like to be represented in your sampler patch. In case of a typical DX-7 E-Piano it might not be all that much, you just want that bell-ish, sometimes a bit hollow character. In this case anything else (such as the mentioned tremolo) can be reproduced on your sampler of choice.
- Depending on the original patches behaviour, decide whether you need much velocity zones or whether you could recreate things more easily on your sampler (such as using the aforementioned velocity to cutoff/attack/sample start modulations).
- Depending on the patches source sound quality, decide whether you need a few or many key zones. As said, many FX (such as simple pitch or volume LFOs) can be recreated easily on almost every sampler, no need to sample these.
Final note about key mappings: Even if you only sampled a very simple signal, such as a sine wave patch, which will just sound the same all throughout the keyboard (apart from changing pitch), it will most likely still be a good idea to sample at least each octave (personally I'm using at least tritones). In case you'll be using less keyzones, the sampler will have to do all the pitching work which a) will result in more CPU useage and b) might result in some aliasing artefacts, depending on the internal sampler engine. And then, in case the sampler has a very high quality internal engine (such as found in sfz(+) or ShortCircuit), this also comes at a cost. More keyzones will use up less CPU power in any case.
There are 3 kinds of people:
Those who can do maths and those who can't.
Those who can do maths and those who can't.
-
- KVRist
- Topic Starter
- 211 posts since 27 Feb, 2005
Thanks Sascha, that's great advice! 
I am planning to use the SFZ format (easier to generate programmatically), which seems to include some functionality for applying different filtering at different velocities, etc. Will look into it for the more
Another quick question: suppose I'm creating a "FM piano soundfont". 127 would be the velocity for highest intensity so I guess I will include that by default. If I was to include only one more velocity for medium intensity, what would that be? 64? Or is velocity logarithmic?
L
I am planning to use the SFZ format (easier to generate programmatically), which seems to include some functionality for applying different filtering at different velocities, etc. Will look into it for the more
Another quick question: suppose I'm creating a "FM piano soundfont". 127 would be the velocity for highest intensity so I guess I will include that by default. If I was to include only one more velocity for medium intensity, what would that be? 64? Or is velocity logarithmic?
L
-
- KVRAF
- 13444 posts since 14 Nov, 2000 from Hannover / Germany
Usually not exactly. But, this is depending a lot on the keyboard you'll be using zo trigger it.Lorenzo333 wrote: Another quick question: suppose I'm creating a "FM piano soundfont". 127 would be the velocity for highest intensity so I guess I will include that by default. If I was to include only one more velocity for medium intensity, what would that be? 64? Or is velocity logarithmic?
On most keyboards I know very low velocities are harder to achieve than very high ones - so in general it'd be better to set the switching point somewhat higher. For patches with 2 zones I usually go for a value between 80 and 90, depending on which of the two I want to be my "main sample".
So, having said that, it's depending on the samples too. There's quite some patches with two zones which have their split points at around, say, 100 or even 110 - so those samples will only sound when you really hit them hard.
Guess it's all a matter of experience and trying things out.
There are 3 kinds of people:
Those who can do maths and those who can't.
Those who can do maths and those who can't.
