ArpeggioSequenceEngine

The ArpeggioSequenceEngine is a SequenceEngine that uses a different pattern for different chord lengths and is therefore suitable for arpeggios.

This SequenceEngine will randomly choose one of the provided patternEngines tags. It will then inspect all contained patternEngine tags within that node and will generate a pattern for each. The pattern lengths for each (in ticks) must be unique, otherwise this is an error condition. For generating a sequence, this SequenceEngine will take the current chord length and will determine the pattern that fits the chord length best: among the provided patterns, it chooses the longest pattern whose length in ticks does not exceed the chord length in ticks. If such a pattern is not found, it will use the longest available pattern instead. That pattern will be used to generate the notes for the current chord.

Imagine that your harmony uses chord lengths of 8, 16 and 32 ticks (which corresponds to 2 beats, 4 beats and 8 beats, respectively, if 4 ticks per beat are used). In this case you should provide 3 patterns (one for each number of ticks), if you want a different pattern for each.



Configuration

Tag Attribute Type # Example Description
normalizeChords - boolean 0-1 false Specifies that chords should be normalized. Defaults to true. Available since version 0.3.
obeyChordSubtype - boolean 0-1 true Specifies if chord subtypes should be obeyed. Defaults to false. Deprecated since version 0.3. Use "normalizeChords" tag with inverted value instead.
obeyChordSections - boolean 0-1 true Specifies if chord sections should be obeyed. If set to true, a chord that spans a chord section boundary will use an arpeggio pattern that ends at the chord section boundary rather than one that ends at the chord's end. Defaults to false. Available since version 0.2.
patternEngines - - 1-n - Groups the PatternEngines.
patternEngines/patternEngine class class 1 StringPatternEngine The name of the PatternEngine implementation to use.
patternEngines/patternEngine - - 1-n - The configuration of the PatternEngine implementation.



Configuration example


<sequenceEngine class="ArpeggioSequenceEngine">
  <normalizeChords>false</normalizeChords>
  <patternEngines>
    <patternEngine class="StringPatternEngine">
      <string>0,0,1,0</string>
    </patternEngine>
    <patternEngine class="StringPatternEngine">
      <string>0,0,1,0,1,1,2,1</string>
    </patternEngine>
    <patternEngine class="StringPatternEngine">
      <string>0,0,1,0,1,1,2,1,2,2,3,2,3,3,4,3</string>
    </patternEngine>
  </patternEngines>
  <patternEngines>
    <patternEngine class="StringPatternEngine">
      <string>0,1,2,1</string>
    </patternEngine>
    <patternEngine class="StringPatternEngine">
      <string>0,1,2,3,4,3,2,1</string>
    </patternEngine>
  </patternEngines>
</sequenceEngine>

Add new comment