How should we implement a MIDI piano roll node?


One of the features likely coming to Audulus 4 is a MIDI piano roll.

Since we have the opportunity to build one from scratch, we could do some really innovative stuff with it.

We’d love to hear your thoughts about how you think it should be implemented.


I’m not sure exactly what you had in mind but the real challenge with MIDI playback is a decent editing environment. I would suggest that rather than trying to include any sort of editing capability, the piano roll should simply provide the ability to playback a series of MIDI notes with velocity from an external MIDI file and allow users to use their editor of choice. You could potentially include channel data, particularly if the trigger nodes become channel sensitive. While it would certainly be possible to include other MIDI message types in the piano roll, you would be duplicating existing functionality that already exists in most DAWs. I see the piano roll as a simple way to playback a series of notes with timing as a more flexible alternative to a traditional sequencer. At minimum the user should be able to control the playback speed, the start and stop position within the file, loop, and have the ability to position the playback pointer. Some possible additions would be the ability to play the file backwards as well as forwards (maybe by making the playback rate negative), and possibly having more than one “playback head” or node playing the same file, perhaps at different rates and directions. A Record mode could also allow the construction of some interesting MIDI based loopers. If trigger nodes were channel sensitive, multiple MIDI streams from different piano roll nodes playing the same or different files could be separated and trigger different elements.


This is an interesting thought, but I’m not quite in agreement. Editing midi notes during playback would open up new avenues of generative music, specifically markovian recursion. It would also create new performance workflows for audulus in the vein of keystep style live permutations of a melody

Basically what I’m saying is there is lots of room for changing the noted of a midi file that you won’t find in cubasis.

That being said, I wouldn’t go down the path of making the piano roll node a mini DAW. I would focus on it’s possibility as a data structure for notes and an engine for capture of live performance.


I was really talking more about a traditional graphical MIDI editor. The KeyStep video is certainly food for thought. Kind of a “drop in” record mode. Doing any kind of programmatic editing on the fly would be cool, but I’m not sure how one would accomplish it in a visual environment. Maybe you could have the ability to add a note on or off event to the roll as it plays. You could potentially build the entire MIDI loop as the patch evolved.


It occurred to me that the ability to record/playback MIDI messages other than notes would also be very useful. In fact if we have MIDI out on UI controls, particularly if high resolution CC messages are supported, it would be a great way to record Audulus automation. Run your patch, start recording, tweak your knobs, and presto, a reproducible performance. Of course in a DAW environment, MIDI out from the controls would be enough since most DAWs already record MIDI, but I would rather do without the overhead unless I’m actually recording.

Why We Bleep Podcast 004: Transistor Sound Labs

I’ve always dreamed of a flexible microtonal piano roll. I realize that it’s likely challenging to implement something without a fixed number of pitches per octave, but it would be incredible and open up a lot of possibilities.

Even if it was confined to 12 pitches per octave, it would be really cool to have each pitch independently tunable for precise microtonal control.

My thought is that if you’re going to have a piano roll, why not open it up to further exploration of the pitch pallette? I mean there are a million piano rolls out there. How many of them are microtunable?

It would be awesome to get away from the arbitrary note names and intervals, and have the ability to input frequency ratios for pitches to explore just intonation. And perhaps a way to create equal temperaments within a given number as well.


Have you tried just scaling the pitch info? You will need to know a little math if you want to be super precise, but taking a regular melody and multiplying it by some value not equal to one you can make some pretty interesting micro tonal results.


There are 128 notes available in the MIDI spec numbered from 0 to 127. The spec defines a frequency for each note with 60 being C4, but there really isn’t anything to prevent you from redefining the frequencies. If you were to define more than 12 notes per octave, you would reduce the overall range that could be covered but even at 24 notes per octave you would have a five octave range. The current MIDI keyboard node outputs frequency rather than note number as a convenience, but it would be fairly simple to convert the frequency back to a MIDI note number. You could then use the note number to trigger any output pitch you would like. It wouldn’t be necessary to alter the MIDI “piano roll” output since you would convert the pitch afterwards.


Here’s an example using the 34EDO scale. I chose the scale because I already had the note values in cents from the microtonal quantizer I built. The first formula converts the frequency from the MIDI keyboard node to a note number. I then offset and scale the value so that I produce an octave with 34 steps using the MIDI notes from C2 to A4 which maps well for my keyboard. The resulting number feeds a 48 channel mux which selects the note offset in cents. I divide by 1200 and add it to the octave value to produce a 1 per octave signal. You could use a similar approach for any scale, and by using a larger mux you wouldn’t even be constrained to octave intervals.

microtonal MIDI.audulus (67.9 KB)


aha! very cool. Thanks for the info. I’m new to Audulus and finding all of this exciting (and a bit overwhelming). Can’t wait to dive in and get weird with all this.


random links…? was that for me, or stschoen?


I was wondering that as well :cowboy_hat_face:



There was have been a few spam bots that will make an account and post a really general comment then, within a day or two, will edit the comment and add spam links. I was directly replying to a suspicious account, which turned out to be spam, so I deleted it. Now my old rely seems cryptic and out of place :sweat_smile:

Sorry about that.

I’ll delete the previous comment.