Last updated: February 12, 2019
Pure-Data (Pd) Programming: How to Get Started
Pure Data, also referred to as Pd, is a visual programming language designed for audio, video, and graphical processing. It allows users to create original software using a graphical interface, rather than lines of code, ideal for musicians, visual artists, and performers with little or no knowledge of coding languages.
Pure Data can be used to generate its own sound, video, and graphics, or it can process input from MIDI, interface sensors, or other input devices. It can also be used for live collaboration across networks, either over a local area network or the Internet, making it possible to control lighting, motor systems, and other stage technologies, or interact with mobile or wearable devices.
Pure Data uses a modular code base, which can incorporate objects that have been developed using other languages, such as C, Python, and Scheme. Once developed, these objects can be added directly into a Pd program, with no additional coding required. Pure Data can also be used to create its own, reusable modules, called patches. Many of these external objects and patches are available for free through Pd’s large open source community, making it even easier for new programmers and digital artists to start using Pd with little to no experience.
Pure Data was developed in 1990s by Miller Puckette as a tool for creating interactive computer music and other multimedia content. Puckette developed Pd shortly after leaving IRCAM, where he also developed Max, another dataflow programming language. As such, Pure Data shares many similarities with Max, and is partially interoperable with Max and its successor, MSP. However, Pure Data is a much more powerful tool for creating computer music than Max, particularly in its ability to handle audio processing directly from the host CPU.
While Puckette first developed Pure Data, the program is largely a collaborative effort. As an open source project, Pure Data has been refined and improved upon by numerous programmers across the world, and the language and its features continue to evolve through the shared community.
Whereas most programming languages utilize a predefined order in which operations occur, from start to finish, or in a path pre-set based on specific commands or actions, dataflow programming focuses instead on the movement of data between objects. Operations run in response to specific input. Once all of an operation’s input requirements become valid, the operation runs. Because operations run based on requirements, rather than a set order, dataflow programming is well suited for decentralized networks.
Many modern dataflow programming languages, including Pure Data, use a visual approach to programming. Programs are created graphically using built-in objects, patches (objects created using the specified programming language — in this case, Pure Data), or even objects developed in another programming language. Objects are placed on a “canvas” and then connected to each other using cords, which direct the data flow between those objects, in much the same way elements of a process flowchart are connected in Microsoft Visio. In this way, it is possible to build full programs in a visual dataflow language without writing a single line of code.
We’ve put together a number of resources to get you going with Pure Data.
Since Pure Data maintains an active open source community, there are plenty of free online tutorials available, many of which are aimed at brand-new users — even non-programmers:
- Pd Tutorials and HOWTOs: the official Pure Data website provides a long list of tutorials and how-to pages, covering basic and advanced concepts of Pure Data programming, as well as software-specific tutorials.
- Pure Data by Floss Manuals: this guide acts as an all-in-one software manual and training guide. It walks you through the initial installation and setup, and then provides dozens of tutorial lessons on audio, video, and dataflow techniques, adding MIDI, utilizing Pd’s networking capabilities, and more. The entire guide is also available as EPUB and PDF downloadable files.
- Programming Electronic Music in Pd by Johannes Kreidler: this free tutorial is designed for composers and uses a hearing-based teaching approach. It starts with basic programming and computer-based acoustic principals, provides theory and application-based lessons on a variety of musical techniques, and builds to the more advanced, technical elements of the language.
Books on Pure Data vary widely, from theory-rich academic texts to project-based app development guides:
- The Theory and Technique of Electronic Music by Miller Puckette: the creator of Pure Data discusses the theories and mathematics behind computer-based musical composition. Puckette has also made it available for free here.
- Multimedia Programming with Pure Data by Bryan WC Chung: this book primarily focuses on the graphical and multimedia capabilities of Pure Data. It includes step-by-step tutorials, visual guides, and information about the many open source resources available.
- Composition: Pure Data as a Meta-Compositional Instrument by Michael Barkl: this book uses original works created in Pure Data to analyze and discuss key elements of computer-based musical composition.
- Programming Sound with Pure Data: Make Your Apps Come Alive with Dynamic Audio by Toni Hillerson: This book teaches Pd techniques specifically tailored for web and mobile app development. It covers Pure Data fundamentals, explains sound design principals, and guides the reader through the development of their own web and mobile projects.
If you can’t find what you’re looking for in the above tutorials and books, these free resources should help you find anything else you may need to get started:
- Miller Puckette’s UCSD Page: Puckette’s homepage at the University of California San Diego provides a variety of resources, including Pure Data documentation and files, a list of classes he’s teaching, and the online version of his book Theory and Techniques of Electronic Music.
- Pure Data Community Pages: this list of community resources includes mailing lists, forums, IRC chat rooms, social media pages, and a YouTube channel dedicated to Pure Data.
Pure Data is a visual programming language specifically designed for create music, video, and other multimedia projects. Being open-source software, it is free to use and supported be a large, active community.
The highly-visual nature of Pure Data makes it an ideal language for digital artist who understand musical composition but may not know, or want to learn, a coding language.