Welcome, Guest
Username: Password: Remember me

TOPIC: Envelope editor

Envelope editor 1 month 3 weeks ago #1

  • Johan Vromans
  • Johan Vromans's Avatar
  • Offline
  • New Member
  • Posts: 5
In a newly created (empty) soundfont, I create an instrument. When I select it and click on the envelope editor, I see an evelope that goes from 0 to max at 0s, continues at max to 2s, and then goes to 0 and stays at zero until 4s.



What does this mean? All values (Delay, Attack, Releasem Hold, Decay, etc) are minimal (0.001s).

I add a sound sample which is 25 seconds long. It is a percussion sound, so I want to sound the complete sample whenever it is invoked, regardless how long the key is pressed. If I understand things correctly, I must set the Hold value to the length of the sample. However, the maximal value for Hold seems to be 5000 samples (18secs). So the best I can do is set Hold to max and set Release to the rest of the length.



Is this correct? Or is there a better way to sound the complete sample?
The administrator has disabled public write access.

Envelope editor 1 month 3 weeks ago #2

  • Michael
  • Michael's Avatar
  • Offline
  • Senior Member
  • Posts: 55
  • Thank you received: 10
When I was less experienced it confused me as well. Still I always use the regular window for editing the envelope.

delay
This refers to the duration of the sound stays muted after the key is pressed. In the majority of cases you want to hear audio immediatly after pressing the keys and then the parameters are left at zero. However delay comes in handy for example when you want to create richer pad sounds constructed with several layers. Suppose you want to introduce a second sound layer 0.5 seconds after the key is pressed, then you can set it by entering "0.5" in the delay-section.

Keep in mind delay does not hold the playback of the sound - it mutes the audio. In practise it means this: suppose you've set the delay to 0.5 seconds, you'll start hearing audio after 0.5 seconds of the sample has already been played.

attack
Here you can set the duration of time the audio-volume goes from zero to maximum after the delay. For example a bowed string sound like a violin has an attack which is relatively quite long, while a plucked string sound such as a guitar is very short.

My advise for this: even when you want to use an attack as short as possible, at least enter a value of 0.001. When you'll leave it blank the attack is absolutely zero and then there might be a change you'll hear some kind of 'clic' after pressing the key.

Hold
The duration of time the volume of the sound stays at its maximum

decay
The duration of time the sound-volume decreases from maximum to the level you've set in the sustain-section. (When you'll leave the sustain-section blank the volume stays at it's maximum no matter which decay-value you've chosen.

sustain
When you want to decrease the volume after "hold" you can set it here. Just as "attenuation" the parameters you can enter here refer to the amount of decibel-reduction. Suppose you want to reduce the volume by its half after the decay-time you'll set a parameter of 6 in the sustain-section.

When you want to deminish the volume to absolutely no sound at all than it's best to enter the number 144. This refers to the dynamics of 24bit audio. (In 24bit audio volume-differences from zero to 144 dB can be stored. Within 16bit the maximum is 96 dB. Within 8bit audio the maximum is 48bit, etc)

release
The duration of time the volume becomes zero after releasing the key. Sounds of violins or synth-pads have a relatively long release time, while that of other sounds (such as organs) are relatively very short.

In practise for short release times you still have to set its duration to at least 0.2 seconds, because a release time which is too short doesn't sound pleasant or natural. (However it also depends what you had in mind about the construction of the instrument you want to create.)

Key → Hold or Key → Decay

When plucking the strings on a guitar or pressing the keys on a piano with the sustain-pedal on you'll notice the lower the tone the longer it lasts untill you'll hear no sound at all.

Here you can simulate it by setting up a scale. The start-point is MIDI-key 60 (also known as the central C on a piano keyboard). No matter which parameters you've set into Key → Hold or Key → Decay, the duration of "Hold" and "Decay" will last as long as you've set with the refering parameters. However, suppose you've entered the number 25 within the section of
"Key → Decay": when you press MIDI-key 48 (one octave below) the decay-time becomes 25% longer lasting. With MIDI-key 72 the decay-time becomes 25% shorter.

It's possible to enter negative values and then it goes the other way round. With a value of -25 the decay-time becomes 25% shorter with MIDI-key 48 and 25% longer with MIDI-key 72


This does not directly answer your question, however I hope it gives you more insight of constructing the envelope and makes it easier to figure out yourself how to use the envelope-window
The administrator has disabled public write access.

Envelope editor 1 month 3 weeks ago #3

  • Johan Vromans
  • Johan Vromans's Avatar
  • Offline
  • New Member
  • Posts: 5
Thanks for the extensive information. While it sheds some light here and there it doesn't really answer my questions (as you already stated).

For example, look at the 2nd image. Hold is set to 18 seconds and Release is about 7 seconds. Yet in the window Hold seems to stretch to 23 seconds and the total length is 30 seconds, a value that I cannot dereive from any of the numbers filled in.
Last Edit: 1 month 3 weeks ago by Johan Vromans.
The administrator has disabled public write access.

Envelope editor 1 month 3 weeks ago #4

  • Michael
  • Michael's Avatar
  • Offline
  • Senior Member
  • Posts: 55
  • Thank you received: 10
I don't know why that is. Polyphone is a very good program but it contains some bugs ... though I wonder that is related to the limitations of the SF2-format itself.

It can also be a problem of FluidSynth: the sound-engine for soundfonts Polyphone is built on. When that's the case you could test your soundfont with a player like this one: Falcosoft Soundfont MIDI Player: its built on the engine BASSMIDI instead of FluidSynth.

To go back to your situation: you've set Hold to 18 seconds, but you haven't set parameters within Sustain, so the 18 seconds to Hold are pointless. Do you want the sample to last for 18 seconds when the player keeps the key on the keyboard pressed? And after those 18 seconds you want the sound to stop abruptly? Then you should set Sustain to 144. If you want to end the sound more smoothly you have to set a higher value than 0.001 seconds.

What you describe about stretching to 23 seconds etc is a problem which is familiar to me as well. It seems to be a bug in the program.

You can also look into the SF2 specification which describes al features possible with soundfonts. (A large document unfortunately which is a pain in the ass to study.)
The administrator has disabled public write access.

Envelope editor 1 month 3 weeks ago #5

  • ziyametedemircan
  • ziyametedemircan's Avatar
  • Offline
  • Premium Member
  • Posts: 110
  • Thank you received: 27
The "Release" parameter is for applying the natural-fade time that the sample will perform whenever it receives the key-off message at any time.

The "Release" parameter skips the hold, decay and sustain parameters as soon as the "note-off" message arrives and goes directly to the release position.

If the key-off occurs before the sample length reaches the end, "release" is applied on the remaining sample-time. But if the sample reaches the end before the "key-off", no action can be taken, because there is nothing else to play.

To avoid this, the sample must have a loop, at least in the last part. so when the sample reaches the end, the loop part is repeated and allows the release.
The administrator has disabled public write access.

Envelope editor 1 month 3 weeks ago #6

  • Johan Vromans
  • Johan Vromans's Avatar
  • Offline
  • New Member
  • Posts: 5
I think that Polyphone uses a 2 second time interval to make the sustain visible in the envelope editor.
In the example below, Attack = 1, Hold = 1, Decay = 1. Then there is a 2 second Sustain, followed by the Release.



So the full length of the envelope in the editor window will always be Attack + Hold + Decay + 2 + Release.

To have a sample sound completely, regardless of when the key is released, the only way seems to be to make the Release as long as possible (102 seconds). Even then, the decrease in volume of a 30 second sample is more than noticeable. And —worse— even though the sound has long stopped, resources will be tied up the full 102 seconds, possibly blocking other samples from sounding.
The administrator has disabled public write access.
Time to create page: 0.080 seconds
Cron Job Starts