Specifications

39
CHAPTER 4
Pure Data Audio
SECTION 4.1
Audio objects
We have loo ked at Pd in enough detail now to move on to the next level.
You have a basic grasp of dataflow programming and know how to make patches
that process numbers and symbols. But why has no mention been made of audio
yet? Surely it is the main purpose of our study? The reason for this is that
audio s ignal pr ocessing is a little more complex in Pd than the numbers and
symbols we have so far consider e d, so I wanted to leave this until now.
Audio connections
I already mentioned that there two kinds of o bjects and data for messag e s
and signals. Corresponding to these there are two kinds of connections, audio
connections and message connections. There is no need to do anything special
to make the right kind of connection. When you connect two objects together
Pd will work out what type of outlet you are attempting to connect to what
kind of inlet and create the appropriate connection. If you try to connect an
audio signal to a message inlet, then Pd will not let you, or it will complain
if there is allowable but ambiguous connection. Audio objects always have a
name ending with a tilde (∼) and the connections between them look fatter
than ordinary message connections.
Blocks
The signal data travelling down audio cords is made of samples, single floating
point values in a sequence that forms an audio signal. Samples are grouped
together in blocks.
+~
31.4 15.9 26.5 35.8
97.9 42.3 84.6 26.4
B
1
B
2
B
3
B
4
A
1
A
2
A
3
A
4
129.3 58.2 111.1 62.2
+BA+BA
1
+B
1
A
2 2 33
A + B
44
Object Box
Inlet
Wire
Signal Block
fig 4.1: Object processing data.
A block, so metimes also called a vector, typ-
ically has 64 samples inside it, but you can
change this in certain circumstances. Ob-
jects opera ting on signal blocks behave like
ordinary mes sage objects, they can add, sub-
tract, delay or store blocks of data, but do
so by processing one whole block at a time.
In Fig. 4 .1 streams of blocks ar e fed to the
two inlets. B locks appe aring at the outlet
have va lues which are the sum of the cor-
responding values in the two input blocks.
Because they process signals made of blocks, audio objects do a lot more work
than objects that process messages.