Last week I came across a post on the Cycling ’74 Wiki about exporting gen~ code into an AU plugin. It looked too simple a process to be true, so I began investigating. After a few hours of work (and some help from the C74 forums because I stumbled across a bug) I managed to get a simple distortion plugin working. The whole process is actually quite simple, after you spend a few agonising hours figuring the system out – like with most things. I must mention that the code export feature in gen~ is still in beta, so things are expected to break. I look forward to a stable release, there’s so much that can be done with such a great sounding DSP library!
What is gen~?
Gen~ is an environment within Max that was introduced in version 6.0. It allows for patching of low level operations that are instantly compiled into great sounding objects without the limitations of MSP. I’ve been using it for about a year now and it sounds absolutely amazing. Version 6.1 of Max makes it possible to export gen~ objects as C++ code, making it portable. Cycling ’74 plans to add documentation for VST plugins and the iOS operating system in the near future.
For this tutorial we are going to attempt to create a tremolo AU plugin (sorry Windows users!). We’ll first start with trying to understand how a tremolo plugin works and implement a basic version within Max (I’ll translate object names for the Pd users out there) and then re-create it within gen~ so that we can export the code that will help create our AU plugin.
DISCLAIMER/WARNING/MESSAGE IN CAPS: gen~ is in beta and there are chances that the code you compile might not work. I’ve got the AU plugin working fine on my computer (OSX 10.7) but haven’t been able to get it to work properly in 10.8. I am also not a coder, I know just enough to hack (or break) my way around things. If you think you’ve come across a bug, do let the kind folks at Cycling ’74 know.
For those of you who just want to play around with the finished project, there is a download link at the bottom of the article. Despite all of this, I’m still relatively new at Pure Data and the Max language. To those who chime in with corrections or clarifications in the comments, you are most appreciated! If you’re new to PD, make sure you check the comments section for clarifying info provided by generous souls.
Last time, we implemented a three stage filter section with independent LFOs to sweep the center/cut-off frequency of each one. Today, we’ll finish up this patch by adding two last features…an anti-aliasing filter and the ability to record to the hard drive directly out of the patch. If you’re somehow just finding this series of tutorials, or you haven’t finished the previous steps, might I suggest you look those up here? This will also be the last time I’ll remind you to setup your MIDI controller in Pure Data before opening your patch. ;)
Guest post by Naila Burney.
A major challenge in video games is to record and manage thousands of dialogue lines. In Mass Effect 3, for example, forty thousand lines were recorded, and in Saints Row: The Third, eighty thousand lines were needed. Having to deal with so much dialogue can be extremely time consuming and expensive. For this reason, I decided to build a prototype of a fictional language dialogue system as a possible solution that would simplify processes and reduce costs. I chose Max/Msp because as a non-programmer, I needed a tool that would allow me to experiment and develop my own rules and behaviors. The high versatility of Max/Msp would let me build the exact design I had in mind.
While we haven’t done an inordinate number of them so far, we’ve created a page to give you quick access to all of the recordings of previous Designing Sound Discussion Group presentations. This should save you the time you’d otherwise have to spend searching the site to find the one specific recording you want to watch.
The direct link now appears in the top menu under the “Archives” tab. Just click on “Webinar/Discussion Group Recordings” to access the aggregation page.
If you haven’t checked out some of the previous presentations, they’re all available to you at the simple click of a mouse. ;)
Guest Contribution by Mark Durham
With this post I want to look at some strategies for generating control data in Max, or more specifically generating complex envelopes for controlling parameters. Now I expect that designing envelopes is nothing new for most Designing Sound readers; it’s been a staple technique for manipulating parameters on a timeline in most DAW’s, samplers etc for some time now. For me, learning to program the first version of Native Instrument’s Absynth was a real revelation with regard to designing complex sounds using envelopes. For anyone who has not tinkered with Absynth, it has a very well designed envelope section and it’s possible to control pretty much any parameter with an envelope. This lends itself very well to complex sequences where different parameters of the synth are being continually adjusted, with each of the parameters interacting to produce sound. Another interesting feature of Absynth is the breakpoint generation tool, which can be used to generate basic repeating envelopes with only a few controls. It’s a large influence on the device featured in this post.