![]() Fortunately it’s easy enough to use: just drop the live.banks into the patcher, open it, and add the two dials you want to be shown on the Push. In general live.banks can be used to manage large set of parameters we use it here because apparently without it sometimes the live.dials won’t show up on the Push. One thing of note here is the use of live.banks. The rest of this box does simple routing, constructing and deconstructing messages of the form scale x, root x, custom1 x and custom2 x. The only thing we have to make sure is to select Parameter Mode Enable and we’re good to go. There are much more sophisticated way to handle pattern storage, but this simple approach will work just fine for our purposes. The two live.dial objects to select the scale and the root note automatically store their own state with the Live set without us having to do anything for the two custom notes (which don’t otherwise have a corresponding UI element), we use a simple pattr object to store their value. Here we collect parameters that make up the state of our device. The bottom two boxes are specific to our instrument: The JavaScript code itself sets autowatch to 0 so that it doesn’t automatically reload when the JavaScript code is saved. To make this convenient during development, pressing the reset button does three things: first, it deletes all observers only then it reloads the JavaScript code, and finally it calls init again. ![]() (We will see how controlButtonMatrix actually works below.)Īt the end of Part 1 we discussed that it is important to explicitly delete observers. We will also respond to messages from live.thisdevice (on its second outlet) that tell us when our device is enabled or disabled, grabbing or release control over Push’s button matrix as appropriate. ![]() Therefore we will send our code an init in response to a bang from live.thisdevice. The top two boxes are not specific to our device, and would be useful in any custom Push instrument:Īs we saw in part 1, we cannot make use of the LiveAPI object until our device has been fully loaded. Let’s briefly discuss the infrastructure around it. If you open the patcher in Max (and exit presentation mode), you will seeĪs before, the logic of the patcher is implemented by the object in the center of it all. You might want to take a quick look to familiarize yourself with this module. In the code, the theory of trichords is implemented in trichordstate.js this is just straight-forward JavaScript code with nothing that is specific to the Push or even to Max for Live or Ableton, so I’ll not discuss it further in this blog post. See the short video on YouTube for a demonstration of how the instrument is used. ![]() We also provide two dials to select a standard scale and a root note for the scale. Our instrument makes this available to the player in a very direct manner: on the left are four buttons that can be used to pick the first note on the right are four buttons to pick the second note and in the middle are six buttons that can be used to actually play the scale. Some standard choices are Scaleīut non-standard choices are possible as well. In other words, the C, F and G are always fixed, but then the note in between the C and the F and the note in between the G and the C can be varied. The basic idea is very simple: scales will consist of two trichords (sequences of three notes) like this: The goal is to develop an instrument that will allow us to easily explore Japanese pentatonic scales using trichords, a term coined in a video by Tommaso Zillio in his YouTube video The Simple Theory Of Japanese Music Scales. What the instrument does, exactly, is not really the point of this blog post, but I’ll briefly describe it just to make it easier to see why we’re doing certain things. If you want to follow along, download Trichord.amxd, place it on a MIDI track, and open the patch in Max. In this part 2 we will get to the fun stuff, and actually develop our Push instrument.Īs a reminder, we want to develop an instrument that has a fully custom Push layout, but integrates nicely with the Ableton workflow: when the track of our instrument is selected, it will show the custom Push layout, but when another track is selected, we get the regular layout: In Part 1 we explored the LiveAPI object object, and used it to construct an abstraction that allows us to monitor when the track that our instrument lives on is selected or deselected. This is part 2 of the two-part series on designing custom Push instruments in Max for Live (using JavaScript). Designing a custom Push2 instrument in Max for Live/JavaScript: Part 2
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |