Skip to content

Options

Hans Lindetorp edited this page Sep 28, 2021 · 1 revision

Random selection

Every region or motif can consist of any number or randomly selected files. Just add sources to the element:

i.e. for Tracks:

<track>
  <region>
    <option src="var1"></option>
    <option src="var2"></option>
    <option src="var3"></option>
    <option src="var4"></option>
    <option src="var5"></option>
  </region>
</track>	

Or for Motifs

<motif>
  <option src="var1"></option>
  <option src="var2"></option>
  <option src="var3"></option>
  <option src="var4"></option>
</motif>

Control the random selection

You can control how the random selection function shall work with the attribute "retrig".

retrig = "next" - everytime the element is triggered it will play the next file in the list. When it reaches the end, it starts all over again.

retrig = "shuffle" - any file could be selected next time (including the one just played)

case "other" - another file than the one just played is selected randomly next time

retrig = "repeat" - the same file is played until a command is called

i.e.

<track retrig="other">

The active-property

The propery "active" can be set on a track determining the likeliness for a region on the track to play. If "active" is set to "0.5" for a track, there is an even chance for the regions on the track to either play or not.

<track active="0.5">
  <region src="bar1"></region>
  <region src="bar2"></region>
  <region src="bar3"></region>
  <region src="bar4"></region>
</track>
Clone this wiki locally