Audio Routes: Using Audio Routes Tooling for your MFL Devices


    The arrival of the Max for Live-based Audio Routes tools, Max for Live and Max users had a set of devices that stunningly demonstrated some new possibilities for taking advantages of Live 10 — multi-channel audio routings, side-chaining, and audio spatialization. I'm sure that Max/Max for Live users the world over were just like me, downloading it from maxforlive.com and just vanishing down the rabbit hole for hours or days while our audio pirouetted or slashed across the soundfield.
    I'll also be willing to be that some of you out there made your way through the set of devices, example Live Sets and detailed documentation and found yourself thinking about creating some multichannel audio devices of your own. I have some great news for you: the Audio Routes system contains some programming that can help you create your own Routes-compatible devices.

    Getting Started

    You can find good examples within the "Audio Routing Example" device:
    M4L programmers can open the device in the Max editor by clicking the Edit button:
    The patching part of the device exposes the basic elements needed to build a multichannel device.
    For starters, notice the multiple arguments to the plugin~ and plugout~ objects, which define the multiple audio inputs and outputs that are exposed to Live.
    Basically, if a device has 8 inputs, it is capable of grabbing 8 audio signals from different tracks in Live. Similarly, if the device has 8 outputs, it is capable of sending 8 audio signals to other tracks in Live.
    Let’s return to that constraint of routing in Live - and, by extension, in the M4L context:
    Routings have to be set as stereo pairs.
    The result of this constraint is that inputs or outputs 1-2, 3-4, 5-6 and 7-8 will be routed together in pairs. To accomplish this, the Audio Routing device offers a small utility in the form of a bpatcher that programmers can copy into their own device.
    This bpatcher, called BrowseRouting.maxpat, has two arguments: the first is either “audio_inputs” or “audio_outputs”, and is used to define the type of target, while the second is the index of a pair of inputs/outputs of the device it refers to, with 1 representing pair 1-2, 2 representing 3-4, 3 for 5-6, and so on.
    A single device may have up to 64 inputs and outputs (32 stereo addressable I/O pairs).

    It's Your Turn

    That's it in terms of getting started, really. With this very quick overview of creating devices that can work within the Audio Routes ecosystem, it's time for some of you to explore and share your work - we are anxious to see what you come up with!
    And Happy Patching!