Selection Filter

Selection Filter

Selection Filter is free and available from maxforlive.com.

Introduction

Selection Filter selects notes in MIDI clips based on their musical properties. The device only selects notes. It doesn’t transform them in any way.

Why is this interesting? Consider the following musical scenarios:

  • You want to transpose every F# to an F.
  • You’ve recorded a drum clip and want to increase the velocity of every offbeat 8th note in the closed hihats.
  • You’ve recorded a series of chords and want to move the bass note of each chord down an octave.
  • You want to delete every muted note.
  • You want to shorten every note that’s longer than a half note.
  • You want to mute all the notes that aren’t in the D Minor scale
  • etc..

In each of these cases, the transformation is very easy — just one or two clicks. But selecting the right notes to transform might be very time-consuming in Live’s MIDI Note Editor.

Selection Filter allows notes to be selected according to nine types of musical criteria:

  • Pitch — select all notes within a range of pitches
  • Scale — select all notes that are members of the chosen scale
  • Highest/Lowest — select the highest (or lowest) note of every chord
  • Velocity — select all notes within a range of velocities
  • Beat position — select notes that begin at a particular rhythmic location within a bar, and then optionally at multiples of that position
  • Duration — select notes within a range of note lengths
  • Nth note — select every Nth note, with an optional offset
  • Active/Inactive — select all notes that are unmuted (or muted)
  • Random — randomly select a fixed number or a percentage of notes

Selection Filter operates on the currently-selected MIDI clip. It won’t work if audio clips or multiple MIDI clips are selected, or on MIDI clips that contain no notes.

Video tutorial

A 22 minute video walkthrough is available below:

Global controls

Go — clicking Go is what actually makes the device do something. Once you’ve set up your selection criteria, click Go to select the notes within the currently selected clip that fit the criteria.

Auto update — when enabled, the selection will be updated immediately after any parameter is changed.

Invert Selection — when enabled, all notes that don’t fit the selection criteria will be selected. 

Filter current selection — when enabled, only the already-selected notes will be tested against the selection criteria. When disabled, the entire clip will be tested. Enable this option if you want to chain multiple types of selection criteria together (for example, to select every note that is between a particular pitch range AND a particular velocity range).

Show clip after running — when enabled, the clip that has been processed will be displayed in Live’s Clip View (if it wasn’t already). This allows you to edit the selected notes immediately.

? — click to open this documentation.

“Select by” criteria

Pitch

Use the Low and High sliders to set the lowest and highest pitches to select. If Select in all octaves is enabled, the selected pitches will be selected in every octave. Click Set pitch range via MIDI to set the low and high values by playing two notes on your MIDI controller. (This requires the MIDI track that contains the Selection Filter device to be armed for recording.) Set pitch range via MIDI will turn off after two notes have been played. When Invert selection is enabled, all notes that are outside of the chosen pitch range will be selected.

Scale

Chose a tonic and scale type from the menus. The selection will then include only notes that are members of that scale, in any octave. When Invert selection is enabled, all notes that are not members of the chosen scale will be selected.

Highest/Lowest

Choose between selecting either the highest or lowest notes in chords. In passages in which only one note is playing at a time, each note will be selected regardless of whether highest or lowest is chosen. The Treat notes within [x] as a chord menu allows for notes that are not precisely simultaneous to be evaluated as if they had occurred simultaneously. This is useful if you’re working with unquantized notes. When Invert selection is enabled, the selection will contain every note besides the highest (or lowest) notes in chords. In passages in which only one note is playing at a time, no notes will be selected.

Velocity

Use the Low and High sliders to set the lowest and highest velocities to select. When Invert selection is enabled, all notes that are outside of the chosen velocity range will be selected.

Beat position

Use the Select and Start at controls to specify a beat position. Clicking Go will then select all notes that begin at that beat position. Note that various combinations of rhythmic values and offsets can refer to the same beat position. For example, each of the following combinations will specify the second quarter note in the bar:

  • Select 1/4 / Start at 2 (the second quarter note)
  • Select 1/8 / Start at 3 (the third eighth note)
  • Select 1/8t / Start at 4 (the fourth eighth-note triplet)
  • Select 1/16 / Start at 5 (the fifth 16th note)
  • etc…

Note that Start at can also be set to a negative value. This is useful if you want to select notes that begin before the downbeat of the first bar. The Within menu allows for notes that are not precisely on the grid to be included in the selection. This is useful if you’re working with unquantized notes. The Repeat every options allow you to specify additional beat positions that are multiples of the original one. For example, to select the second sixteenth note of each beat, set the following values:

  • Select 1/16 / Start at 2 / Repeat every 1 1/4

Note that various combinations of Repeat every values can refer to the same beat positions. In the previous example, Repeat every 2 1/8 would have the same effect.  When Invert selection is enabled, all notes that begin somewhere other than the specified beat positions will be selected.

Duration

Use the Low and High menus to set the shortest and longest note durations to select. The menus include two non-specific durations: <1/128 and >whole. These select all notes that are very short (less than a 128th note) or very long (longer than a whole note). When Invert selection is enabled, all notes that are outside of the range of note lengths will be selected.

Nth note

Selects every Nth note (from left to right in time) with an optional offset (the Start at value). For example, the settings in the above image will select every 5th note starting at the 2nd note. Simultaneous notes are counted from the lowest pitch to the highest. When Invert selection is enabled, all notes that are not every N are selected.

Active/Inactive

Selects all notes that are unmuted (Active) or muted (Inactive). Enabling Invert selection has the same effect as choosing the opposite menu option.

Random

Randomly selects either a fixed number of notes or a percentage of the available notes. When Invert selection is enabled, a random collection of notes is still selected, but the selection will contain every note except the number you’ve chosen. For example, if you choose to randomize two notes, the inverse will be a randomized selection of all but two notes. If you choose to randomize 25% of the notes, the inverse will be a randomized selection of 75% of the notes.

Tips and tricks

Preserving your selection

After making a selection of notes, you’ll want to edit them, which usually requires working in Live’s MIDI Note Editor. But this is surprisingly difficult, because clicking almost anywhere in the MIDI Note Editor will deselect all notes. To focus the Note Editor without breaking your selection, click in places that show the mouse pointer as a magnifying glass. These “safe” places include the Note Ruler on the left and the zoom area above the Loop Brace.

Understanding Filter current selection

The Filter current selection option uses the current selection of notes as the basis for the next selection. This is extremely powerful, but may also be confusing. For example, when working with Nth note on the entire clip, every note is counted. But when working with only a partial selection of notes, only those notes are counted. With Filter current selection enabled, this will yield increasingly smaller numbers of notes each time you click Go, even with the same parameters. If zero notes are selected, the next selection will evaluate the entire clip.

Some examples

Now that the controls have been explained, let’s look at how to accomplish the specific musical scenarios discussed earlier.

You want to transpose every F# to an F

  • in the Selection Filter device, enable Show clip after running
  • select by Pitch
  • enable Select in all octaves
  • select F#/G♭ in both the Low and High menus
  • click Go
  • in Live’s MIDI Note Editor, click in a “safe” area to preserve your selection
  • Press the Down Arrow key on your computer keyboard to transpose the selected notes down a half step

You’ve recorded a drum clip and want to increase the velocity of every offbeat 8th note in the closed hihats.

  • in Live’s MIDI Note Editor, select all the closed hihat notes by clicking their key in the piano roll 
  • in the Selection Filter device, enable Filter current selection.
  • enable Show clip after running
  • select by Beat position
  • select 1/8 / Start at 2 / Repeat every 1 1/4
  • click Go
  • in Live’s MIDI Note Editor, click and drag the velocity of one of the selected notes

You’ve recorded a series of chords and want to move the bass note of each chord down an octave.

  • in the Selection Filter device, enable Show clip after running
  • select by Highest/Lowest
  • Select lowest notes
  • (adjust Treat notes within [x] as a chord as necessary)
  • click Go
  • in Live’s MIDI Note Editor, click in a “safe” area to preserve your selection
  • Press Shift + the Down Arrow key on your computer keyboard to transpose the selected notes down an octave

You want to delete every muted note.

  • in the Selection Filter device, enable Show clip after running
  • select by Active/Inactive
  • Select inactive notes
  • click Go
  • in Live’s MIDI Note Editor, click in a “safe” area to preserve your selection
  • Press the Delete key on your computer keyboard to delete the selected notes

You want to shorten every note that’s longer than a half note.

  • in the Selection Filter device, enable Show clip after running
  • select by Duration
  • select Low 1/2 / High >whole
  • Click Go
  • in Live’s MIDI Note Editor, click in a “safe” area to preserve your selection
  • Click and drag the right edge of one of the selected notes

You want to mute all the notes that aren’t in the D Minor scale

  • in the Selection Filter device, enable Show clip after running
  • enable Invert selection
  • select by Scale
  • Select D Minor
  • click Go
  • in Live’s MIDI Note Editor, click in a “safe” area to preserve your selection
  • Press the 0 key on your computer keyboard to deactivate the selected notes

Known issues

Extremely short durations

Under certain conditions, Selection Filter will increase the duration of extremely short notes (less than 1/2048th note) by a very small amount. If you are using these notes and they’re directly adjacent to other notes, the increased durations may cause the adjacent notes to be deleted. (In practice, this situation will almost never occur.)

Notes that extend across a clip’s loop boundaries

When recording into a looping clip, Live splits notes that sustain across the loop boundary, and assigns the first of these notes a start time that is just slightly before the beginning of the clip. Under certain conditions, Selection Filter may move the start time of these notes earlier by a very small amount. This may cause the clip to sound different. (In practice, this situation will almost never occur.)

Randomly selecting large numbers of notes

Random selection may not work properly when working with more than 4096 notes.

Live 9 (or older)

Selection Filter does not work with versions of Live prior to Live 10.