Professional Documents
Culture Documents
Emsd1 001 42
Emsd1 001 42
To app ly an envelope to a raw wavefo rm (that is to say, a wave that has con-
stant ampli t ude), we iterat ively mult iply, poi nt by poi nt, th e sample values for
t he envelope w ith those of t he sound itself. The values of an envelope wi ll
norma lly vary betwee n O and 1. The envelo pe depicted in the f igure begi ns and
ends wi t h the value 0, and reaches 1 at the end of its attack; the values of all
of it s othe r samples fall between O and 1. If we mult iply, on e by one, t his series
of values w ith the sample values contai ned in t he waveform (which, remember,
fa ll betwee n - 1 and 1), we scale th e ampl itude of the waveform by the shape
of the envelope. At t he begi nning of th e note, for example, t he amp lit ude of
t he waveform wil l be scaled to O (t he dig ital equivalent of silence), because t he
first value of t he envelope is 0, and any number multi plied by O is 0 . As the
sample values in the envelope increase, so does the resulting prod uct, unt il the
maximum point is reached at t he end of t he attack , wh ere the envelope wil l
have a value of 1, and wi ll the refore have no eff ect on the correspond ing value
in the wavefo rm, since any number multiplied by 1 is equal to itself . Cont inuing
wit h the rest of th e envelop e, wav efo rm samples wil l always be scaled by num-
bers t hat lie between O and 1, which means t hat t he waveform's ampl itude wi ll
always occupy some positi on between silence (0) and maximum amp litude (1).
Finally, at th e end of the envelope 's release, th e waveform samples, mu lti plied
by 0, wi ll fall silent once again .
. .. .. . . . . . . . . . . . . . . . .. . . .. ... .. . . . ... .. . . . . . . .. . . . . . . . . . . .
INTERACTIVE EXAMPLE 1F • LINEAR ENVELOPES