SoundHelix-Popcorn.xml 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395
  1. <?xml version="1.0"?>
  2. <!-- Example XML file for SoundHelix. Author: Thomas Schuerger. -->
  3. <SoundHelix version="0.8+" xmlns:xi="http://www.w3.org/2001/XInclude">
  4. <xi:include href="../includes/Standard-SongNameEngine.xml" />
  5. <structure>
  6. <bars>
  7. <random min="192" max="300" step="16" />
  8. </bars>
  9. <beatsPerBar>4</beatsPerBar>
  10. <ticksPerBeat>12</ticksPerBeat>
  11. <maxVelocity>1000</maxVelocity>
  12. </structure>
  13. <harmonyEngine class="PatternHarmonyEngine">
  14. <crossoverPitch>5</crossoverPitch>
  15. <minimizeChordDistance>false</minimizeChordDistance>
  16. <chordPattern>Am/10,G/2,F/2,Am/12,G/2,F/2,Am/2,+C/8,Em/2,D/2,C/12,Em/2,D/2,C/4</chordPattern>
  17. </harmonyEngine>
  18. <arrangementEngine class="SimpleArrangementEngine">
  19. <constraintMode>greedy</constraintMode>
  20. <maxIterations>2500</maxIterations>
  21. <minActivityCount>3</minActivityCount>
  22. <maxActivityCount>6</maxActivityCount>
  23. <maxActivityChangeCount>1</maxActivityChangeCount>
  24. <startActivityCounts>
  25. <random list="1,2,3|2,3,4" />
  26. </startActivityCounts>
  27. <stopActivityCounts>
  28. <random list="4,3|5,3,2|5,4,2|5,4,3" />
  29. </stopActivityCounts>
  30. <activityVector name="base_snare">
  31. <startAfterSection>1</startAfterSection>
  32. <startBeforeSection>4</startBeforeSection>
  33. <stopBeforeSection>0</stopBeforeSection>
  34. <stopAfterSection>3</stopAfterSection>
  35. <minActive>50</minActive>
  36. <maxActive>90</maxActive>
  37. <minSegmentLength>2</minSegmentLength>
  38. <maxSegmentLength>8</maxSegmentLength>
  39. <maxPauseLength>3</maxPauseLength>
  40. <minSegmentCount>2</minSegmentCount>
  41. <maxSegmentCount>5</maxSegmentCount>
  42. </activityVector>
  43. <activityVector name="clap">
  44. <startAfterSection>1</startAfterSection>
  45. <minActive>15</minActive>
  46. <minSegmentLength>2</minSegmentLength>
  47. </activityVector>
  48. <activityVector name="hihat">
  49. <startAfterSection>0</startAfterSection>
  50. <minActive>30</minActive>
  51. <minSegmentLength>3</minSegmentLength>
  52. <minSegmentCount>2</minSegmentCount>
  53. </activityVector>
  54. <activityVector name="melody">
  55. <startAfterSection>0</startAfterSection>
  56. <startBeforeSection>3</startBeforeSection>
  57. <minActive>30</minActive>
  58. <startShift>-12</startShift>
  59. <stopShift>-12</stopShift>
  60. <minSegmentLength>2</minSegmentLength>
  61. </activityVector>
  62. <activityVector name="chords">
  63. <startBeforeSection>1</startBeforeSection>
  64. <minActive>20</minActive>
  65. <minSegmentLength>2</minSegmentLength>
  66. </activityVector>
  67. <activityVector name="accomp">
  68. <startBeforeSection>2</startBeforeSection>
  69. <minActive>20</minActive>
  70. <minSegmentLength>2</minSegmentLength>
  71. </activityVector>
  72. <activityVector name="bass">
  73. <startAfterSection>1</startAfterSection>
  74. <minActive>20</minActive>
  75. <minSegmentLength>2</minSegmentLength>
  76. </activityVector>
  77. <activityVector name="string">
  78. <startAfterSection>3</startAfterSection>
  79. <minActive>20</minActive>
  80. <minSegmentLength>2</minSegmentLength>
  81. </activityVector>
  82. <activityVector name="pad">
  83. <startAfterSection>1</startAfterSection>
  84. <minActive>20</minActive>
  85. <minSegmentLength>2</minSegmentLength>
  86. </activityVector>
  87. <activityVector name="arpeggio">
  88. <startAfterSection>4</startAfterSection>
  89. <minActive>10</minActive>
  90. <minSegmentLength>2</minSegmentLength>
  91. </activityVector>
  92. <track>
  93. <instrument>percussion</instrument>
  94. <sequenceEngine class="DrumSequenceEngine">
  95. <pattern>
  96. <!-- base drum -->
  97. <pitch>36</pitch>
  98. <patternEngine class="RandomFragmentPatternEngine">
  99. <patternTicks>16</patternTicks>
  100. <ticksPerBeat>4</ticksPerBeat>
  101. <patternString>
  102. <random list="A1,B1,A1,B2,A1,B1,A1,B3|A1,A1,A1,B1,A1,A1,A1,B2,A1,A1,A1,B1,A1,A1,A1,B3" />
  103. </patternString>
  104. <pattern group="A">0,-,-,-,-,-,-,-,0,-,-,-,-,-,-,-</pattern>
  105. <pattern group="B">0,-,0,-,-,-,-,-,0,-,-,-,-,-,-,-|0,-,-,0,-,-,-,-,0,-,-,-,-,-,-,-|0,-,-,-,-,-,-,-,0,-,-,-,-,-,0,-|0,-,-,-,-,-,-,-,0,-,-,-,-,-,-,0|0,-,-,-,-,-,-,-,0,-,-,-,-,-,0,0|0,-,-,-,-,-,-,0,-,-,0,-,-,-,-,-|0,-,-,-,-,-,-,0,-,0,0,-,-,-,-,-|0,-,-,-,-,-,0,-,0,-,-,-,-,-,-,-</pattern>
  106. </patternEngine>
  107. </pattern>
  108. <pattern>
  109. <!-- snare drum -->
  110. <pitch>38</pitch>
  111. <patternEngine class="RandomFragmentPatternEngine">
  112. <patternTicks>8</patternTicks>
  113. <ticksPerBeat>4</ticksPerBeat>
  114. <patternString>
  115. <random list="A1,A1,A1,B1,A1,A1,A1,C1,A1,A1,A1,B1,A1,A1,A1,C2|A1,A1,A1,A1,A1,A1,A1,B1,A1,A1,A1,A1,A1,A1,A1,C1,A1,A1,A1,A1,A1,A1,A1,B1,A1,A1,A1,A1,A1,A1,A1,C2"/>
  116. </patternString>
  117. <pattern group="A">-,-,-,-,0,-,-,-</pattern>
  118. <pattern group="B">-,-,-,-,0,-,-,-|-,-,-,-,0,-,-,0</pattern>
  119. <pattern group="C">-,-,-,-,0,-,-,0|-,-,-,0,0,-,0,-|-,-,-,0,0,0,-,0|-,-,-,0,0,0,0,-|-,0,-,0,0,0,0,-|-,-,-,0,-,-,0,-|-,-,-,0,-,0,-,-|-,-,-,0,-,0,-,0</pattern>
  120. </patternEngine>
  121. </pattern>
  122. <pattern>
  123. <!-- clap -->
  124. <pitch>39</pitch>
  125. <patternEngine class="RandomFragmentPatternEngine">
  126. <patternTicks>16</patternTicks>
  127. <ticksPerBeat>4</ticksPerBeat>
  128. <patternString>
  129. <random list="A1,B1,A1,B2|A1,B1,A1,B2,A1,B1,A1,B3|A1,A1,A1,B1,A1,A1,A1,B2,A1,A1,A1,B1,A1,A1,A1,B3|C1,A1,C1,B1,C1,A1,C1,B2"/>
  130. </patternString>
  131. <pattern group="A">-/12,0,-/3</pattern>
  132. <pattern group="B">-/11,0:500,0,-/3|-/12,0,0,-/2|-/12,0,0,-,0|-/9,0,-,-,0,-/3|-/9,0,-,-,0,-,0,-</pattern>
  133. <pattern group="C">-/16</pattern>
  134. </patternEngine>
  135. </pattern>
  136. <pattern>
  137. <!-- closed hihat -->
  138. <pitch>42</pitch>
  139. <patternEngine class="RandomFragmentPatternEngine">
  140. <patternTicks>4</patternTicks>
  141. <ticksPerBeat>4</ticksPerBeat>
  142. <patternString>A1,A2,A1,A3,A1,A2,A1,A4</patternString>
  143. <pattern group="A">0:800,0:800,0:800,0:800|0:800,0:800,-,0:800|0:800,-,-,-|0:800,-,0:800,-|0:800,0:800,0:800,-</pattern>
  144. </patternEngine>
  145. </pattern>
  146. <pattern>
  147. <!-- open hihat -->
  148. <pitch>46</pitch>
  149. <patternEngine class="RandomFragmentPatternEngine">
  150. <patternTicks>8</patternTicks>
  151. <ticksPerBeat>4</ticksPerBeat>
  152. <patternString>
  153. <random list="A1,B1,A1,B2,A1,B1,A1,B3|A1,A1,A1,B1,A1,A1,A1,B2|A1,A1,A1,B1,A1,A1,A1,B2,A1,A1,A1,B1,A1,A1,A1,B3"/>
  154. </patternString>
  155. <pattern group="A">-,-,0:600,-,-,-,0:600,-</pattern>
  156. <pattern group="B">-,-,0:600,-,-,-,0:600,-|-,-,0:600,-,-,-,0:600,-|-,-,0:600,-,-,-,0:600,-|-,-,0:600,-,-,-,-,0:600|-,-,0:600,-,-,0:600,-,0:600</pattern>
  157. </patternEngine>
  158. </pattern>
  159. <pattern>
  160. <!-- empty melody (used so that we can have a conditional pattern using the melody in conditions) -->
  161. <pitch>46</pitch>
  162. <patternEngine class="StringPatternEngine">
  163. <string>-</string>
  164. </patternEngine>
  165. </pattern>
  166. <pattern>
  167. <!-- empty track for crash cymbal -->
  168. <pitch>57</pitch>
  169. <patternEngine class="StringPatternEngine">
  170. <string>-</string>
  171. </patternEngine>
  172. </pattern>
  173. <conditionalPattern>
  174. <target>0</target>
  175. <precondition>-base_snare</precondition>
  176. <postcondition>+base_snare</postcondition>
  177. <mode>replace</mode>
  178. <probability>60</probability>
  179. <patternEngine class="CrescendoPatternEngine">
  180. <patternTicks>
  181. <random list="48|96" />
  182. </patternTicks>
  183. <minVelocity>1</minVelocity>
  184. <maxVelocity>1000</maxVelocity>
  185. <velocityExponent>1</velocityExponent>
  186. <pattern ticksPerBeat="4">
  187. <random list="0,-,-,-|0" />
  188. </pattern>
  189. </patternEngine>
  190. </conditionalPattern>
  191. <conditionalPattern>
  192. <target>1</target>
  193. <precondition>-base_snare</precondition>
  194. <postcondition>+base_snare</postcondition>
  195. <mode>replace</mode>
  196. <probability>60</probability>
  197. <patternEngine class="CrescendoPatternEngine">
  198. <patternTicks>
  199. <random list="96|192" />
  200. </patternTicks>
  201. <minVelocity>1</minVelocity>
  202. <maxVelocity>1000</maxVelocity>
  203. <velocityExponent>1</velocityExponent>
  204. <pattern ticksPerBeat="4">
  205. <random list="0/1|0/1:1000,0/1:700|0,-,-,0,-,-,0,-" />
  206. </pattern>
  207. <suffixPattern ticksPerBeat="6">
  208. <random list="(0)*6|(0)*12|0/2,0/2,0/2,0/2,-/4"/>
  209. </suffixPattern>
  210. </patternEngine>
  211. </conditionalPattern>
  212. <conditionalPattern>
  213. <target>6</target>
  214. <precondition>-base_snare</precondition>
  215. <postcondition>+base_snare</postcondition>
  216. <mode>replace</mode>
  217. <probability>70</probability>
  218. <patternEngine class="CrescendoPatternEngine">
  219. <patternTicks>
  220. <random list="48" />
  221. </patternTicks>
  222. <minVelocity>600</minVelocity>
  223. <maxVelocity>1000</maxVelocity>
  224. <velocityExponent>1</velocityExponent>
  225. <pattern ticksPerBeat="1">
  226. <random list="0" />
  227. </pattern>
  228. </patternEngine>
  229. </conditionalPattern>
  230. <conditionalPattern>
  231. <target>0,1</target>
  232. <precondition>+base_snare,-hihat</precondition>
  233. <postcondition>+base_snare,+hihat</postcondition>
  234. <mode>replace</mode>
  235. <probability>60</probability>
  236. <patternEngine class="StringPatternEngine">
  237. <string ticksPerBeat="4">
  238. <random list="-/16|-/8" />
  239. </string>
  240. </patternEngine>
  241. </conditionalPattern>
  242. <conditionalPattern>
  243. <target>0</target>
  244. <precondition>-melody</precondition>
  245. <postcondition>+melody,+base_snare</postcondition>
  246. <mode>replace</mode>
  247. <probability>100</probability>
  248. <patternEngine class="StringPatternEngine">
  249. <string ticksPerBeat="3">0,0,0,0,-,-</string>
  250. </patternEngine>
  251. </conditionalPattern>
  252. </sequenceEngine>
  253. <activityVector>base_snare</activityVector>
  254. <activityVector>base_snare</activityVector>
  255. <activityVector>clap</activityVector>
  256. <activityVector>hihat</activityVector>
  257. <activityVector>hihat</activityVector>
  258. <activityVector>melody</activityVector>
  259. <activityVector>base_snare</activityVector>
  260. </track>
  261. <track>
  262. <instrument>melody</instrument>
  263. <transposition>0</transposition>
  264. <sequenceEngine class="FreePatternSequenceEngine">
  265. <patternEngine class="StringPatternEngine">
  266. <string ticksPerBeat="4">9,-,4,-,0,-,4,-,-3,-,-,-,9,-,7,-,9,-,4,-,0,-,4,-,-3,-,-,-,9,-,11,-,12,-,11,-,12,-,9,-,11,-,9,-,11,-,7,-,9,-,7,-,9,-,5,-,9,-,-,-,9,-,7,-,9,-,4,-,0,-,4,-,-3,-,-,-,9,-,7,-,9,-,4,-,0,-,4,-,-3,-,-,-,9,-,11,-,12,-,11,-,12,-,9,-,11,-,9,-,11,-,7,-,9,-,7,-,9,-,5,-,9,-,-,-,16,-,14,-,16,-,12,-,7,-,12,-,4,-,-,-,16,-,14,-,16,-,12,-,7,-,12,-,4,-,-,-,16,-,18,-,19,-,18,-,19,-,16,-,18,-,16,-,18,-,14,-,16,-,14,-,16,-,12,-,16,-,-,-,16,-,14,-,16,-,12,-,7,-,12,-,4,-,-,-,16,-,14,-,16,-,12,-,7,-,12,-,4,-,-,-,16,-,18,-,19,-,18,-,19,-,16,-,18,-,16,-,18,-,14,-,16,-,14,-,16,-,12,-,16,-,-,-,9,-,7,-,9,-,4,-,0,4,-,-3,-,-,-,-,9,-,7,-,9,-,4,-,0,4,-,-3,-,-,-,-,9,-,11,-,12,-,11,12,-,12,9,-,11,-,9,11,-,11,7,-,9,-,7,9,-,9,5,-,9,-,-,-,9,-,7,-,9,-,4,-,0,4,-,-3,-,-,-,-,9,-,7,-,9,-,4,-,0,4,-,-3,-,-,-,-,9,-,11,-,12,-,11,12,-,12,9,-,11,-,9,11,-,11,7,-,9,-,7,9,-,9,5,-,9,-,-,-,16,-,14,-,16,-,12,-,7,12,-,4,-,-,-,-,16,-,14,-,16,-,12,-,7,12,-,4,-,-,-,-,16,-,18,-,19,-,18,19,-,19,16,-,18,-,16,18,-,18,14,-,16,-,14,16,-,16,12,-,16,-,-,-,16,-,14,-,16,-,12,-,7,12,-,4,-,-,-,-,16,-,14,-,16,-,12,-,7,12,-,4,-,-,-,-,16,-,18,-,19,-,18,19,-,19,16,-,18,-,16,18,-,18,14,-,16,-,14,16,-,16,12,-,16,-,-,-,9,-,7,-</string>
  267. </patternEngine>
  268. </sequenceEngine>
  269. <activityVector>melody</activityVector>
  270. </track>
  271. <track>
  272. <instrument>accomp</instrument>
  273. <velocity>600</velocity>
  274. <transposition>-24</transposition>
  275. <sequenceEngine class="PatternSequenceEngine">
  276. <patternEngine class="StringPatternEngine">
  277. <string ticksPerBeat="4">0,-,3,2,-1,-,3,2,0,-,3,2,-1,0,2,3,0,-,3,2,-1,-,3,2,0,-,3,2,-1,0,2,3,0,-,3,2,-1,0,2,3,0,-,3,2,-1,0,2,3,0,-,3,2,-1,-,3,2,0,-,3,2,-1,0,2,3</string>
  278. </patternEngine>
  279. </sequenceEngine>
  280. <activityVector>accomp</activityVector>
  281. </track>
  282. <track>
  283. <instrument>chords</instrument>
  284. <transposition>0</transposition>
  285. <velocity>600</velocity>
  286. <sequenceEngine class="ChordSequenceEngine">
  287. <patternEngine class="StringPatternEngine">
  288. <string ticksPerBeat="4">0,-,-,0,-,-,0,-</string>
  289. <string ticksPerBeat="4">0,-,-,0,-,-,0,-,0,-,-,0,-,-,0,-,0,-,-,0,-,-,0,-,0,-,-,0,-,0,-,0</string>
  290. </patternEngine>
  291. </sequenceEngine>
  292. <activityVector>chords</activityVector>
  293. </track>
  294. <track>
  295. <transposition>-36</transposition>
  296. <instrument>bass</instrument>
  297. <sequenceEngine class="PatternSequenceEngine">
  298. <patternEngine class="RandomPatternEngine">
  299. <patternTicks>16</patternTicks>
  300. <patternString>
  301. <random list="A1,A2,A1,A3|A1,A2,A1,A3"/>
  302. </patternString>
  303. <noteProbability>70</noteProbability>
  304. <legatoProbability>0</legatoProbability>
  305. <minVelocity>1000</minVelocity>
  306. <maxVelocity>1000</maxVelocity>
  307. <minActiveTicks>10</minActiveTicks>
  308. <maxActiveTicks>14</maxActiveTicks>
  309. <offsets>0,0,0,3</offsets>
  310. <noteLengths>1,1,1,1,1,2,1</noteLengths>
  311. <pauseLengths>1</pauseLengths>
  312. <pitchVelocityCorrelation>0</pitchVelocityCorrelation>
  313. <velocityExponent>1</velocityExponent>
  314. <ticksPerBeat>4</ticksPerBeat>
  315. </patternEngine>
  316. </sequenceEngine>
  317. <activityVector>bass</activityVector>
  318. </track>
  319. <track>
  320. <instrument>string</instrument>
  321. <velocity>600</velocity>
  322. <transposition>-12</transposition>
  323. <sequenceEngine class="FreePatternSequenceEngine">
  324. <patternEngine class="StringPatternEngine">
  325. <string ticksPerBeat="4">(0/14,-1/2,0/4,-3/8,0/2,2/2,4/6,0/2,2/6,-1/2,0/8,-3/8)*2,4/14,2/2,4/4,0/8,4/2,6/2,7/6,4/2,6/6,2/2,4/8,0/8,4/14,2/2,4/4,0/8,4/2,6/2,7/6,4/2,6/6,2/2,4/16</string>
  326. </patternEngine>
  327. </sequenceEngine>
  328. <activityVector>string</activityVector>
  329. </track>
  330. <track>
  331. <transposition>0</transposition>
  332. <velocity>400</velocity>
  333. <instrument>pad</instrument>
  334. <sequenceEngine class="PadSequenceEngine">
  335. <offsets>
  336. <random list="-3,0,1,2,3|-1,0,1,2"/>
  337. </offsets>
  338. </sequenceEngine>
  339. <activityVector>pad</activityVector>
  340. </track>
  341. <track>
  342. <instrument>arpeggio</instrument>
  343. <velocity>600</velocity>
  344. <transposition>0</transposition>
  345. <sequenceEngine class="PatternSequenceEngine">
  346. <patternEngine class="RandomFragmentPatternEngine">
  347. <patternTicks>24</patternTicks>
  348. <ticksPerBeat>12</ticksPerBeat>
  349. <uniquePatternParts>false</uniquePatternParts>
  350. <patternString>
  351. <random list="A1,B1,A2,B2,A1,B1,A2,B3|A1,A1,A1,B1,A1,A1,A1,B2|A1,A1,A1,B1,A1,A1,A1,B2,A1,A1,A1,B1,A1,A1,A1,B3"/>
  352. </patternString>
  353. <pattern group="A">0/3,1/3,2/3,3/3,4/3,1/3,4/3,3/3|0/3,1/3,2/3,3/3,4/3,5/3,4/3,2/3|0/3,1/3,3/3,5/3,4/3,2/3,3/3,1/3</pattern>
  354. <pattern group="B">0/3,1/3,2/3,3/3,-/3,5/3,4/3,-/3|0/3,1/3,-/3,3/3,6/3,-/3,4/3,2/3|0/3,1/3,4/3,-/3,3/2,5/2,4/2,1/2,4/2,3/2|0/3,4/3,-/3,2/3,5/2,3/2,6/2,2/2,4/2,1/2</pattern>
  355. </patternEngine>
  356. </sequenceEngine>
  357. <activityVector>arpeggio</activityVector>
  358. </track>
  359. </arrangementEngine>
  360. <player class="MidiPlayer">
  361. <bpm>
  362. <random min="124" max="138" type="normal" variance="7" />
  363. </bpm>
  364. <transposition><random min="65" max="68"/></transposition>
  365. <beforePlayWaitTicks>16</beforePlayWaitTicks>
  366. <afterPlayWaitTicks>16</afterPlayWaitTicks>
  367. <groove>
  368. <random list="100|110,110,110,90,90,90|115,115,115,85,85,85" />
  369. </groove>
  370. <!-- uncomment the following line if you want to write all generated songs as MIDI files in the subdirectory "midifiles" -->
  371. <!-- <midiFilename>midifiles/SoundHelix-Popcorn_-_${safeSongName}.mid</midiFilename> -->
  372. <device name="device1" clockSynchronization="true">Gervill,Microsoft GS Wavetable Synth,Microsoft GS Wavetable SW Synth,Java Sound Synthesizer</device>
  373. <!-- <synchronizationDevice waitForStart="true">timingport</synchronizationDevice> -->
  374. <map instrument="percussion" device="device1" channel="10" />
  375. <map instrument="melody" device="device1" channel="1" program="1" />
  376. <map instrument="chords" device="device1" channel="2" program="1" />
  377. <map instrument="accomp" device="device1" channel="3" program="1" />
  378. <map instrument="bass" device="device1" channel="4" program="36"/>
  379. <map instrument="string" device="device1" channel="5" program="41"/>
  380. <map instrument="pad" device="device1" channel="8" program="83"/>
  381. <map instrument="arpeggio" device="device1" channel="9" program="9"/>
  382. </player>
  383. </SoundHelix>