Pure Data
Encyclopedia
Pure Data is a visual programming language
Visual programming language
In computing, a visual programming language is any programming language that lets users create programs by manipulating program elements graphically rather than by specifying them textually. A VPL allows programming with visual expressions, spatial arrangements of text and graphic symbols, used...

 developed by Miller Puckette
Miller Puckette
Miller Smith Puckette is the associate director of the Center for Research in Computing and the Arts as well as a professor of music at the University of California, San Diego, where he has been since 1994....

 in the 1990s for creating interactive
Interaction
Interaction is a kind of action that occurs as two or more objects have an effect upon one another. The idea of a two-way effect is essential in the concept of interaction, as opposed to a one-way causal effect...

 computer music
Computer music
Computer music is a term that was originally used within academia to describe a field of study relating to the applications of computing technology in music composition; particularly that stemming from the Western art music tradition...

 and multimedia
Multimedia
Multimedia is media and content that uses a combination of different content forms. The term can be used as a noun or as an adjective describing a medium as having multiple content forms. The term is used in contrast to media which use only rudimentary computer display such as text-only, or...

 works. While Puckette is the main author of the program, Pd is an open source
Open source
The term open source describes practices in production and development that promote access to the end product's source materials. Some consider open source a philosophy, others consider it a pragmatic methodology...

 project with a large developer base working on new extensions to it. It is released under a license similar to the BSD license. It runs on GNU/Linux
Linux
Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution. The defining component of any Linux system is the Linux kernel, an operating system kernel first released October 5, 1991 by Linus Torvalds...

, Mac OS X
Mac OS X
Mac OS X is a series of Unix-based operating systems and graphical user interfaces developed, marketed, and sold by Apple Inc. Since 2002, has been included with all new Macintosh computer systems...

, iOS
IOS
iOS is an operating system for iPad, iPhone, iPod Touch, and Apple TV.IOS may also refer to:-Companies and organisations:* Illinois Ornithological Society, American state-based bird club...

, Android and Windows. Older ports exist for FreeBSD
FreeBSD
FreeBSD is a free Unix-like operating system descended from AT&T UNIX via BSD UNIX. Although for legal reasons FreeBSD cannot be called “UNIX”, as the direct descendant of BSD UNIX , FreeBSD’s internals and system APIs are UNIX-compliant...

 and IRIX
IRIX
IRIX is a computer operating system developed by Silicon Graphics, Inc. to run natively on their 32- and 64-bit MIPS architecture workstations and servers. It was based on UNIX System V with BSD extensions. IRIX was the first operating system to include the XFS file system.The last major version...

.

Pd is very similar in scope and design to Puckette's original Max
Max (software)
Max is a visual programming language for music and multimedia developed and maintained by San Francisco-based software company Cycling '74. During its 20-year history, it has been widely used by composers, performers, software designers, researchers, and artists for creating innovative recordings,...

 program, developed while he was at IRCAM
IRCAM
IRCAM is a European institute for science about music and sound and avant garde electro-acoustical art music. It is situated next to, and is organizationally linked with, the Centre Pompidou in Paris...

, and is to some degree interoperable with Max/MSP, the commercial successor to the Max language. They may be collectively discussed as members of the Patcher family of languages.

With the addition of the Graphics Environment for Multimedia
Graphics Environment for Multimedia
Graphics Environment for Multimedia is a set of externals that provide OpenGL graphics functionality to Pure Data, a graphical programming language for real-time audio processing. It is free under the GNU General Public License ....

 (GEM) external, and externals designed to work with it (like Pure Data Packet / PiDiP for Linux, Mac OS X), framestein for Windows, GridFlow (as n-dimensional matrix processing, for Linux, Mac OS X, Windows), it is possible to create and manipulate video, OpenGL
OpenGL
OpenGL is a standard specification defining a cross-language, cross-platform API for writing applications that produce 2D and 3D computer graphics. The interface consists of over 250 different function calls which can be used to draw complex three-dimensional scenes from simple primitives. OpenGL...

 graphics, images, etc., in realtime with seemingly endless possibilities for interactivity with audio, external sensors, etc.

Pd is natively designed to enable live collaboration across networks or the Internet, allowing musicians connected via LAN or even in disparate parts of the globe to create music together in real time.

Similarities to Max

Pure Data and Max are both arguably examples of dataflow programming languages. In such languages, functions or “objects” are linked or “patched” together in a graphical environment which models the flow of the control and audio. Unlike the original version of Max, however, Pd was always designed to do control-rate and audio processing on the host central processing unit
Central processing unit
The central processing unit is the portion of a computer system that carries out the instructions of a computer program, to perform the basic arithmetical, logical, and input/output operations of the system. The CPU plays a role somewhat analogous to the brain in the computer. The term has been in...

 (CPU), rather than offloading the sound synthesis and signal processing
Signal processing
Signal processing is an area of systems engineering, electrical engineering and applied mathematics that deals with operations on or analysis of signals, in either discrete or continuous time...

 to a digital signal processor
Digital signal processor
A digital signal processor is a specialized microprocessor with an architecture optimized for the fast operational needs of digital signal processing.-Typical characteristics:...

 (DSP) board (such as the Ariel ISPW
ISPW
The IRCAM Signal Processing Workstation was a hardware DSP platform developed by IRCAM and the Ariel Corporation in the late 1980s. In French, the ISPW is referred to as the SIM ....

 which was used for Max/FTS). Pd code forms the basis of David Zicarelli's MSP extensions to the Max language to do software audio processing.

Like Max, Pd has a modular
Modularity (programming)
Modular programming is a software design technique that increases the extent to which software is composed of separate, interchangeable components called modules by breaking down program functions into modules, each of which accomplishes one function and contains everything necessary to accomplish...

 code base of externals or objects which are used as building blocks for programs written in the software. This makes the program arbitrarily extensible through a public API, and encourages developers to add their own control and audio routines, in the programming languages C
C (programming language)
C is a general-purpose computer programming language developed between 1969 and 1973 by Dennis Ritchie at the Bell Telephone Laboratories for use with the Unix operating system....

, or with the help of other externals, in Python
Python (programming language)
Python is a general-purpose, high-level programming language whose design philosophy emphasizes code readability. Python claims to "[combine] remarkable power with very clear syntax", and its standard library is large and comprehensive...

, Scheme, Lua
Lua
Lua may refer to:* Lua , a Roman goddess* Lua , a traditional Hawaiian martial art* Lua , a lightweight, extensible programming language* Lua , a single by the folk rock band Bright Eyes...

, Tcl
Tcl
Tcl is a scripting language created by John Ousterhout. Originally "born out of frustration", according to the author, with programmers devising their own languages intended to be embedded into applications, Tcl gained acceptance on its own...

, and many others. However, Pd is also a programming language. Modular, reusable units of code written natively in Pd, called “patches” or “abstractions”, are used as standalone programs and freely shared among the Pd user community, and no other programming skill is required to use Pd effectively.

Language features

Like Max, Pd is a data flow programming language. As with most DSP
Digital signal processing
Digital signal processing is concerned with the representation of discrete time signals by a sequence of numbers or symbols and the processing of these signals. Digital signal processing and analog signal processing are subfields of signal processing...

 software, there are two primary rates at which data is passed: sample (audio) rate, usually at 44,100 samples per second, and control rate, at 1 block per 64 samples. Control messages and audio signals generally flow from the top of the screen to the bottom between "objects" connected via inlets and outlets.
Pd supports 4 basic types of text entities: messages, objects, atoms, and comments. Atoms are the most basic unit of data in Pd, and they consist of either a float
Floating point
In computing, floating point describes a method of representing real numbers in a way that can support a wide range of values. Numbers are, in general, represented approximately to a fixed number of significant digits and scaled using an exponent. The base for the scaling is normally 2, 10 or 16...

, a symbol, or a pointer to a datastructure. (In Pd, all numbers are stored as 32-bit floats). Messages are composed of one or more atoms and provide instructions to objects. A special type of message with null content is called a bang is used to initiate events and push data into flowing, much like pushing a button.

Pd's native objects range from the basic mathematical, logical, and bitwise operators found in every programming language, to general and specialized audio-rate DSP functions (designated by a tilde (~) symbol), such as wavetable oscillators, the Fast Fourier transform
Fast Fourier transform
A fast Fourier transform is an efficient algorithm to compute the discrete Fourier transform and its inverse. "The FFT has been called the most important numerical algorithm of our lifetime ." There are many distinct FFT algorithms involving a wide range of mathematics, from simple...

 (fft~), and a range of standard filters
Filter design
Filter design is the process of designing a filter , often a linear shift-invariant filter, that satisfies a set of requirements, some of which are contradictory...

. Data can be loaded from file, read in from an audio board, MIDI, via Open Sound Control (OSC) through a Firewire, USB, or network connection, or generated on the fly, and stored in tables, which can then be read back and used as audio signals or control data.

Data structures

One of the key innovations in Pd over its predecessors has been the introduction of graphical data structure
Data structure
In computer science, a data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently.Different kinds of data structures are suited to different kinds of applications, and some are highly specialized to specific tasks...

s, which can be used in a large variety of ways, from composing musical scores, sequencing events, to creating visuals to accompany Pd patches or even extending Pd's GUI
Gui
Gui or guee is a generic term to refer to grilled dishes in Korean cuisine. These most commonly have meat or fish as their primary ingredient, but may in some cases also comprise grilled vegetables or other vegetarian ingredients. The term derives from the verb, "gupda" in Korean, which literally...

.

Living up to Pd's name, data structures enable Pd users to create arbitrarily complex static as well as dynamic or animated graphical representations of musical data. Much like C structs, Pd's structs are composed of any combination of floats, symbols, and array data, which can be used as parameters to describe the visual appearance of the data structure or, conversely, to control messages and audio signals in a Pd patch. In Puckette's words:

Projects using Pure Data

Pure Data has been used as the basis of a number of projects, as a prototyping language and a sound engine. The table interface called the Reactable
Reactable
The Reactable is an electronic musical instrument with a tabletop Tangible User Interface that has been developed within the at the Universitat Pompeu Fabra in Barcelona, Spain by Sergi Jordà, Marcos Alonso, Martin Kaltenbrunner and Günter Geiger....

 and the iPhone app rjdj both embed Pd as a sound engine.

Pd has been used for prototyping audio for video games by a number of audio designers. For example, EAPd is the internal version of Pd that is used at Electronic Arts
Electronic Arts
Electronic Arts, Inc. is a major American developer, marketer, publisher and distributor of video games. Founded and incorporated on May 28, 1982 by Trip Hawkins, the company was a pioneer of the early home computer games industry and was notable for promoting the designers and programmers...

 (EA). It has also been embedded into EA Spore
Spore (2008 video game)
Spore is a multi-genre single-player god game developed by Maxis and designed by Will Wright. The game was released for the Microsoft Windows and Macintosh operating systems in September 2008 as Spore...



Pd has also been used for networked performance, in the Networked Resources for Collaborative Improvisation (NRCI) Library.

Code examples

  1. The first patch prints "Hello world" to the display.
  2. The second patch applies reverberation to the incoming signal from channel 1, then emits it on channels 1 and 2.
  3. The last, more complex patch filters white noise at 9000 hertz (with a Q of 20), then fades it in and out each second over the course of a half second. As in all of Pd, time is measured in milliseconds, thus the '1000' is one second and the '500' is a half second.

See also

  • Graphics Environment for Multimedia
    Graphics Environment for Multimedia
    Graphics Environment for Multimedia is a set of externals that provide OpenGL graphics functionality to Pure Data, a graphical programming language for real-time audio processing. It is free under the GNU General Public License ....

  • Max/Msp
  • reacTable
    Reactable
    The Reactable is an electronic musical instrument with a tabletop Tangible User Interface that has been developed within the at the Universitat Pompeu Fabra in Barcelona, Spain by Sergi Jordà, Marcos Alonso, Martin Kaltenbrunner and Günter Geiger....

  • Puredyne
  • Comparison of audio synthesis environments
    Comparison of audio synthesis environments
    Software audio synthesis environments typically consist of an audio programming language and a user environment to design/run the language in. Although many of these environments are comparable in their abilities to produce high-quality audio, their differences and specialties are what draw users...


Books

(This contains the proceedings of the First International Pd-Convention held at Graz
Graz
The more recent population figures do not give the whole picture as only people with principal residence status are counted and people with secondary residence status are not. Most of the people with secondary residence status in Graz are students...

 in 2004) (Not a book about Pure Data per se, but all examples in the book are in PD)

External links

The source of this article is wikipedia, the free encyclopedia.  The text of this article is licensed under the GFDL.
 
x
OK