DSP Implementation 479 the wind-speed control by 100ms and 1000ms, causing the whistle on the right
to follow behind the one on the left. In other words, the wind direction in this
model is left to right with respect to the observer.
Tree Leaves This isn’t a particularly good leaves effect, but I’ve included it because it does
show some useful techniques. Notice first of all the delay of 2s followed by a low
filter. This lags the effect considerably so it follows behind the wind movement.
If you notice the way leaves on a tree sound, they seem to have a kind of inertia.
Figure 41.13 Tree leaves.
They take a while to build up their energy then take
a while to quiet down once the gust stops, proba-
bly because springy branches keep them shaking for
a while. Next, the control signal is reduced, then
inverted, so it moves down from 0
. 7 to 0
. 4. Apply-
ing this to
and
creates a mask that passes
only the top excursions. If there is a high value on the
right inlet of
(a low wind speed) then only a few
spikes of the noise pass through, producing a sparse
crackle. As the wind speed increases, the
threshold
lowers and more noise spikes come through, making a
denser sound. Subtracting the threshold from the out-
put returns the signal base to zero, and scaling it by
the same threshold restores it to a normalised ampli-
tude, so sparse crackles sound as loud as dense ones.
To approximate rustling leaves a pair of filters reduces
the low and high ends of the spectrum.
Howls Now let’s add some moaning and howling to the scene. This is what we expect
from resonant spaces like pipes and doorways. To make this effect interesting
we’ll implement a critical range of Reynolds values and have each howl appear
within a particular range of wind speeds. The two patches shown in figure 41.14
are almost identical. You may abstract the patch and make arguments of the
band-pass frequency and oscillator values in order to create a few slightly dif-
ferent instances. Starting with the signal from
, each howl is set to come in
at slightly different times of 100ms and 300ms. Next we use
to pick out a
range of wind speeds over which the howl will occur. Subtracting the lower clip
value resets the base to zero. Multiplying by 2
. 0 and subtracting 0
. 25 sets the
domain for a single positive going sine cycle from
. Because this can be brief
if the speed moves quickly past our threshold window, a low-pass filter slugs
the movement to always take a couple of seconds. The next part is interesting.
We amplitude modulate a fixed and narrow band of noise. This gives a noisy
oscillator sweep with side bands that behave like a fixed formant, just as the
changing vortex frequencies excite the resonant space in a forced oscillation.