Using the Live API abstractions

Michael TerrenMax for LiveLeave a Comment

Max for Live: Jamming the Live API

Continuing his Live API series of blog posts, Michael Terren shows us how to use the Max for Live Abstractions to easily make useful devices.

download NAVI as part of Michael Terren’s suite of Max for Live Devices
Getting into Max for Live can seem intimidating when starting out, and I wouldn’t blame you for admitting that because I was exactly the same. There are a handful of ways for beginners to dip their toes in, so to speak, like Max’s extensive help files and tutorials, but in case they’re too extensive for you, allow me to introduce the Max for Live API Abstractions.

The Max for Live API Abstractions are basically really handy shortcuts that let you do simple things in Live without the legwork. Think of them as normal Max patches, abstracted to look like normal Max objects. These are really useful—for example, you could use Max to fire a clip with just one ‘object,’ or you can navigate between scenes and tracks with ease, or start and stop the Transport, all with minimal effort.

To access these, you head to the Max toolbar (the top of the screen for Mac, the top of the window for Windows), click ‘Extras’, and click M4L.api.ListOfAbstractions. You’ll see this screen pop up:

m4l-api-abstractions

The Max for Live API Abstractions Overview window

This is the list of Abstractions that Max offers you. Click on one of them and the abstraction pops up in another Max window.

You’ll see the abstraction and some explanatory text. To use this in your Max for Live patch, simply unlock it, select it all (or press Command-A), or take just the abstraction itself (the object with the M4L.api.ToggleTransport name), copy, and paste it into your Max for Live patch.

m4l-api-toggletransport

You might need to re-initialise Max for Live for this to take effect—to do this simply create a ‘live.thisdevice’ object and double-click it (failing that, save the patch, close it and reopen it again).

You can also type the Max for Live API Abstractions directly into your patch. Create a new object as per normal, type “m4l.api” and you’ll see the abstractions appearing underneath the object. Press the down arrow to scroll through these and select the one you want. This will load that abstraction exactly as before.

m4l-api-autocomplete-crop

And if you’re ready to go deeper into the Max for Live API, you can double click on any of these abstractions and a window will pop up showing you how they work. These are very useful ways to get started with the Live API.
m4l-api-doubleclicked

We can do a lot of useful things just using the Live API abstractions. Here, I’ve made a patch that I use a fair bit, which lets you use the keyboard to navigate around the Session View using the keyboard. NAVI, as I’ve called it, just uses the Live API abstractions, specifically “M4L.api.SelectNextTrack”, “M4L.api.SelectPreviousTrack”, “M4L.api.SelectNextScene”, and “M4L.api.SelectPreviousScene”. Map each of these to, say, ‘W’, ‘A’, ‘S’ and ‘D’ on your keyboard (like how you would move around in a first-person shooter game) and now you can navigate between clips and scenes really easily. Don’t forget that to fire the selected clip from the keyboard, you can hit ‘Enter’.

navinavi patch

download NAVI as part of Michael Terren’s suite of Max for Live Devices

You can achieve a lot with just these Max for Live API Abstractions, and I’ll come back to them from time to time. Have fun with NAVI, and have fun with the abstractions!

Michael TerrenUsing the Live API abstractions

Leave a Reply

Your email address will not be published. Required fields are marked *