I’ve spent the past 4 days and nights completely re-coding my now 2400-line algorithm. Here are key features (demo at bottom):
This program integrates three approaches to generating polyphonic music: through arps, mels (i.e. melodies), and pads. Arps build short phrases out of motifs and have brief rhythm durations (adjustable). Mels all perform the currently active theme (see the next paragraph) in consonant chord intervals (all adjustable). Pads generate long notes in consonant chord intervals.
This program integrates chord progressions, motifs, and rhythms to generate themes. Themes have a chance of playing whenever the active chord is the tonic. For coherence, I personally find it best to limit the number of themes in a piece to 2: 1 fixed and 1 replaceable.
The music can change keys during performance, with changes being reflected in the bar following a change. For now, I’ve provided a simple set of heptatonic keys (C ionian, D dorian, E phrygian, F lydian, G mixolydian, and A aeolian). (Not B locrian, and if you add it, make sure to remove constraints on tritones.)
CC controls have been improved and integrated in all sections. The addition of legato too enables the use of more articulations.
The implementation supports any number of MIDI ports. It is best not to have more than say 6 instruments playing any section at once however!
All this runs with minimal timing warnings. I haven’t looked at my CPU usage, but it seems fine.
I have here a demo with 96 channels, half orchestral strings and winds, and half synths. It’s a busy piece, and overall I like it: 20210217 - Sections (v0.2.0) by d0lfyn | Free Listening on SoundCloud
Perhaps this demo is better, with 48 channels, all orchestral strings and winds: 202010215B - Sections (v0.2.0) by d0lfyn | Free Listening on SoundCloud
Enjoy!