class PowerQuantise

Staggeringly impressive Phrase quantisation. More...

Full nameTSE3::Util::PowerQuantise
Definition#include <PowerQuantise.h>
List of all Methods
Annotated List

Public Types

Public Methods

Detailed Description

This utility class provides you with more quantising capabilities than you ever dreamt possible.

The class is used by specifying the set of parameters to run the PowerQuantise with, and then providing a (tidied) PhraseEdit object containing the source MidiData to quantise. Once the PowerQuantiser is run, the PhraseEdit will contain tidied, (powerfully) quantised MidiData.

Some of the facilities provided by PowerQuantise are:

To be completed This class isn't a Notifer yet, but it will be. I imagine that the PowerQuantise::Pattern class will also be Serializable so that you can save a library of named patterns. Watch this space.

See also: PhraseEdit, PowerQuantise::Pattern

 PowerQuantise ()


Creates a PowerQuantise object with a sensible default set-up.

Pattern (class)


This class represents the PowerQuantise pattern, or 'groove'. It is basically a set of Clock points which the PowerQuantise should snap events to.

See also: PowerQuantise

Pattern & pattern ()


int  by ()



Returns the percentage by which events will be quantised towards a snap point. 100% will move the command exactly to the snap point. 50% will move it half way towards it. 110% will move the event just past the snap point.

This is a way of preventing the quantised MidiData from sounding too mechanised.

See also: setBy

void  setBy (int by)


Sets the percentage shift value.

See also: by

int  window ()



This is a percentage value that controls which MIDI events get quantised. At 0% no events will be quantised. As the value increases, events near to (and then further away from) snaps points begin to get quantised. At 100% all MIDI events will be quantised.

See also: setWindow

void  setWindow (int window)


Sets the window value.

See also: setWindow

bool  onlySelected ()



If true, this parameter forces PowerQuantise to only alter selected events. (This uses the selected bit in a MidiCommand). If false, PowerQuantise alters all events (that pass other event filters).

See also: setOnlySelected

void  setOnlySelected (bool s)


Sets the onlySelected value.

See also: onlySelected

bool  onlyNotes ()



If true, this parameter forces PowerQuantise to only alter note MIDI events. If false, PowerQuantise alters all events (that pass other event filters).

See also: setOnlyNotes

void  setOnlyNotes (bool n)


Sets the onlyNotes value.

See also: onlyNotes

bool  spreadCtrl ()



This is a very powerful feature that prevents continuous MIDI controller events (pitch bend, pan, reverb, etc) being pulled toward snap points as most sequencers will do. This tends to remove the continuous nature of the pattern of these events.

Enabling this feature spreads the controllers between their surrounding note events after the quantisation. This spread will follow the same pattern that they originally were positoned in. This means that pitch bend slides, for example, will sound pretty much as they did prior to the quantise.

See also: setSpreadCtrl

void  setSpreadCtrl (bool s)


Sets the spreadCtrl value.

See also: spreadCtrl

enum Direction { nearest, backwards, forwards }


Direction  direction ()



This returns which snap point a MIDI event moves towards. This will normally be the nearest available snap point, but you can shoose to snap all events forwards or backwards.

See also: setDirection

void  setDirection (Direction d)


Sets the direction value.

See also: direction

enum Length { quantiseOffTime, quantiseLength }


Length  length ()



This returns what PowerQuantise does with MidiCommand_NoteOffs. You can choose to either snap the length of a MidiCommand_NoteOn to MidiCommand_NoteOff to the pattern, or quantise the actual time of the MidiCommand_NoteOff.

You can also specify separate percentage shift and humanise values for note lengths.

See also: setDirection

void  setLength (Length l)


Sets the length value.

See also: length

int  lengthBy ()



Returns the percentage by which note lengths are moved towards their quantised value.

See also: by, setLengthBy

void  setLengthBy (int by)


Sets the percentage shift value.

See also: lengthBy

TSE3::Clock  humanise ()



After an event is quantised, you can choose to have it moved by a random value (up to the a specified number of pulses which is returned by this function).

This is an alternative way of preventing the quantised MidiData sounding 'mechanised' by introducing slight human-like errors.

A value of zero will disable the humanise facility.

See also: setHumanise, lengthHumanzie

void  setHumanise (TSE3::Clock h)


Sets the humanise value.

See also: humanise

TSE3::Clock  lengthHumanise ()



This is a separate value of humanise which applies to MidiCommand_NoteOff MIDI events.

See also: humanise, setLengthHumanise

void  setLengthHumanise (TSE3::Clock h)


Sets the length humanise value.

See also: lengthHumanise

void  go (TSE3::PhraseEdit *phraseEdit)


Do the PowerQuantise on the given PhraseEdit.