Envelopes & sample pitch

Started by TheRealByteraver, March 18, 2019, 22:49:48

Previous topic - Next topic

TheRealByteraver

Sorry if this has been asked before!
I have a question regarding envelope handling in "primitive" tracker programs such as FT2 and IT. From what I can gather, the speed at which you process the envelope is dependent not on the pitch of the sample but on the BPM the song is playing at. Since trackers use frequency shifting to produce different tones the samples are played faster or slower depending on their frequency. This means the envelope points are not always on same "spot" in the sample data. Sorry for the weird explanation, I suppose you get what I'm on about? Is that a "necessary evil" / limitation of the time? Is this being dealt differently nowadays? Or is it just not that big of an issue?

I guess the only way to avoid the "problem" is to use samples whose sound does not change too much (like a piano), or have an instrument with several samples for the same instrument?


Edit:typo

LPChip

Your explanation is correct. This is very much by design and preferred.

Oneshot samples should not have an envelope in the first place, and when you have a loop, then the envelope makes sense. I would not know why one would want the envelope to change depending on pitch. It is that the way samples work makes that this happens for samples.

The idea here is that you use samples that have a consistent volume (no attack or decay in them) with loop points, so you can make the instrument envelope do its magic.

Of course, if you use plugins (VST Instruments) the entire plugin behaves like this, which is what many people do nowadays. But I still do use samples, and then I just ensure that either the sample has no volume envelope, or the sample has no volume changes which makes using a volume envelope weird.

And yes, when emulating real instruments, the more samples you have for different tone heights, the more realistic the instrument will sound, and the more precise the volume envelope will behave, but if you go this route and you want to aim for high quality, best practice would suggest to use one-shot samples which have the entire tail in them and not use a separate volume envelope.

This will create a huge instrument in terms of filesize though, so what people often do is create a loop point in the sample at the beginning of its tail, and then use a volume envelope to emulate how the tail would otherwise sound. Its not perfect though, but that gets the filesize down dramatically.
"Heh, maybe I should've joined the compo only because it would've meant I wouldn't have had to worry about a damn EQ or compressor for a change. " - Atlantis
"yes.. I think in this case it was wishful thinking: MPT is makng my life hard so it must be wrong" - Rewbs

nikku4211

Quote from: LPChip on March 19, 2019, 08:39:58
This will create a huge instrument in terms of filesize though, so what people often do is create a loop point in the sample at the beginning of its tail, and then use a volume envelope to emulate how the tail would otherwise sound. Its not perfect though, but that gets the filesize down dramatically.

Glad to see some people still care about filesize.

Saga Musix

Yes, it is very much intentional that envelopes always run at the same speed (being processed on every tick of the row). I mean, if we lived in a perfect world where some laws of physics didn't apply the speed change in playing samples wouldn't happen but since that is not the case, I would say the way samples behave is a "necessary evil", not the way instrument envelopes behave. Some synthesizers allow a sample-like effect on envelopes: They have a parameter which changes the envelope speed based on the note played, so the envelope could last longer (or even shorter if you use a different value!) if you play them at a lower octave. However, this principle is somewhat incompatible with how envelopes work in modules so it's currently not possible to have this as a feature in OpenMPT.
» 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.

TheRealByteraver

Thanks guys, that answers my question. I realized that if one uses decent instruments with good loops (GUS patches maybe? I'm not a musician) this shouldn't be all that much of an issue in practice.