Debian Codegraph @

src/Examples/McCurdy Collection/GranularSynthesis/grain.csd

raw
1 ;Written by Iain McCurdy, 2011
2
3 ;Modified for QuteCsound by René, May 2011
4 ;Tested on Ubuntu 10.04 with csound-float 5.13.0 and QuteCsound svn rev 817
5
6 ;Notes on modifications from original csd:
7 ; Add Browser for audio files and power of two tables for grain opcode, accept mono or stereo wav files
8 ; Instrument 1 is activated by MIDI and by the GUI, added pitchbend
9 ; Removed Recording instrument 99, included in QuteCsound
10 ; Add INIT instrument using QuteCsound Presets system
11
12
13 ;my flags on Ubuntu: -odac -b1024 -B2048 -+rtaudio=alsa -+rtmidi=alsa -Ma -m0 --midi-key-oct=4 --midi-velocity-amp=5
14 <CsoundSynthesizer>
15 <CsOptions>
16 --env:SSDIR+=../../SourceMaterials
17 </CsOptions>
18 <CsInstruments>
19 sr = 44100 ;SAMPLE RATE
20 ksmps = 64 ;NUMBER OF AUDIO SAMPLES IN EACH CONTROL CYCLE
21 nchnls = 2 ;NUMBER OF CHANNELS (2=STEREO)
22 0dbfs = 1 ;MAXIMUM AMPLITUDE REGARDLESS OF BIT DEPTH
23
24
25 ;THE SOUND FILES USED IN THE GRANULATION
26 gisine ftgen 0, 0, 4096, 10, 1 ;SINE WAVE
27 gibuzz ftgen 0, 0, 2048, 11, 30, 1, 0.8 ;BUZZ WAVEFORM
28
29 giratio ftgen 0, 0, 4096, -16, 0.125, 1024, 4, 4
30 gicps ftgen 0, 0, 4096, -16, 50, 1024, 4, 2000
31
32 ;GRAIN ENVELOPE WINDOW FUNCTION TABLES:
33 giwfn1 ftgen 0, 0, 512, 20, 2 ; HANNING WINDOW
34 giwfn2 ftgen 0, 0, 512, 7, 0, 12, 1, 500, 0 ; PERCUSSIVE - STRAIGHT SEGMENTS
35 giwfn3 ftgen 0, 0, 512, 5, 0.001, 12, 1, 500, 0.001 ; PERCUSSIVE - EXPONENTIAL SEGMENTS
36 giwfn4 ftgen 0, 0, 512, 7, 0, 6, 1, 500, 1, 6, 0 ; GATE - WITH ANTI-CLICK RAMP UP AND RAMP DOWN SEGMENTS
37 giwfn5 ftgen 0, 0, 512, 7, 0, 500, 1, 12, 0 ; REVERSE PERCUSSIVE - STRAIGHT SEGMENTS
38 giwfn6 ftgen 0, 0, 512, 5, 0.001, 500, 1, 12, 0.001 ; REVERSE PERCUSSIVE - EXPONENTIAL SEGMENTS
39
40 gaRvbSendL init 0
41 gaRvbSendR init 0
42
43
44 instr 10 ;GUI
45 ktrig metro 10
46 if (ktrig == 1) then
47 ;BUTTONS
48 gkgrnd invalue "Pointer"
49 gkMIDIToPch invalue "MIDItoPch"
50 gkMIDIToDens invalue "MIDItoDens"
51 ;SLIDERS
52 gkamp invalue "Amplitude"
53 gkdur invalue "GrainDuration"
54 gkratio invalue "PitchRatio"
55 gkcps invalue "PitchCPS"
56 gkfmd invalue "PitchRnd"
57 gkdens invalue "Density"
58 gkDensRnd invalue "DensityRnd"
59 gkampoff invalue "AmpOffset"
60 gkAtt invalue "Attack"
61 gkRel invalue "Release"
62 gkRvbAmt invalue "Level"
63 gkRvbSize invalue "Size"
64 ;MENUS
65 gkwfn invalue "GrainEnvelope"
66 gksfn invalue "Input"
67
68 ;AUDIO FILE CHANGE / LOAD IN POWER OF 2 TABLES **********************************************************************************************
69 Sfile_new strcpy "" ;INIT TO EMPTY STRING
70
71 Sfile invalue "_Browse"
72 Sfile_old strcpyk Sfile_new
73 Sfile_new strcpyk Sfile
74 kfile strcmpk Sfile_new, Sfile_old
75
76 gkfile_new init 0
77 if kfile != 0 then ;IF A BANG HAD BEEN GENERATED IN THE LINE ABOVE
78 gkfile_new = 1 ;Flag to inform instr 1 that a new file is loaded
79 reinit NEW_FILE ;REINITIALIZE FROM LABEL 'NEW_FILE'
80 endif
81 NEW_FILE:
82 ;grain accept only power of 2 table size
83 ifnTemp ftgentmp 0, 0, 0, 1, Sfile, 0, 0, 1 ;Temporary table to get the audio file size
84 iftlen = ftlen(ifnTemp) ;file size
85 giftlen2 pow 2, ceil(log(iftlen)/log(2)) ;high nearest power of two table size
86
87 ;FUNCTION TABLES NUMBERS OF THE SOUND FILE THAT WILL BE GRANULATED
88 ichn filenchnls Sfile
89 if ichn == 1 then
90 giFileL ftgentmp 0, 0, giftlen2, 1, Sfile, 0, 0, 1 ;READ MONO AUDIO FILE CHANNEL 1
91 giFileR = giFileL
92 else
93 giFileL ftgentmp 0, 0, giftlen2, 1, Sfile, 0, 0, 1 ;READ STEREO AUDIO FILE CHANNEL 1
94 giFileR ftgentmp 0, 0, giftlen2, 1, Sfile, 0, 0, 2 ;READ STEREO AUDIO FILE CHANNEL 2
95 endif
96 ;*******************************************************************************************************************************************
97 endif
98 endin
99
100 instr 1 ;GRAIN INSTRUMENT
101 if p4!=0 then ;MIDI
102 ioct = p4 ;READ OCT VALUE FROM MIDI INPUT
103 ;PITCH BEND=============================================================================================
104 iSemitoneBendRange = 12 ;PITCH BEND RANGE IN SEMITONES
105 imin = 0 ;EQUILIBRIUM POSITION
106 imax = iSemitoneBendRange * .0833333 ;MAX PITCH DISPLACEMENT (IN oct FORMAT)
107 kbend pchbend imin, imax ;PITCH BEND VARIABLE (IN oct FORMAT)
108 kcps = cpsoct(ioct + kbend) ;SET FUNDAMENTAL
109 ;=======================================================================================================
110 endif
111
112 kporttime linseg 0, 0.001, 0.1 ;CREATE A VARIABLE FUNCTION THAT RAPIDLY RAMPS UP TO A SET VALUE
113
114 if p4!=0 && gkMIDIToPch=1 then ;IF THIS IS A MIDI ACTIVATED NOTE AND MIDI-TO-PITCH SWITCH IS ON...
115 kratio = kcps/cpsoct(8) ;MAP TO MIDI NOTE VALUE TO PITCH (CONVERT TO RATIO: MIDDLE C IS POINT OF UNISON)
116 else ;OTHERWISE...
117 kratio portk gkratio, kporttime ;USE THE GUI SLIDER VALUE
118 kcps portk gkcps, kporttime ;USE THE GUI SLIDER VALUE
119 endif ;END OF THIS CONDITIONAL BRANCH
120
121 if p4!=0 && gkMIDIToDens=1 then ;IF THIS IS A MIDI ACTIVATED NOTE AND MIDI-TO-DENSITY SWITCH IS ON...
122 kdens = kcps ;MAP TO MIDI NOTE VALUE TO GRAIN DENSITY
123 else ;OTHERWISE...
124 kdens portk gkdens, kporttime ;PORTAMENTO IS APPLIED TO SMOOTH VALUE CHANGES VIA THE GUI SLIDERS
125 endif ;END OF THIS CONDITIONAL BRANCH
126
127 if gkfile_new = 1 then ;test if a new file is loaded by instr 10
128 gkfile_new = 0 ;flag to zero for next file change
129 reinit START ;REINITIALIZE FROM LABEL 'NEW_FILE1'
130 endif
131
132 kSwitch changed gkwfn, gksfn, gkgrnd
133 if kSwitch=1 then ;IF I-RATE VARIABLE CHANGE TRIGGER IS '1'...
134 reinit START ;BEGIN A REINITIALISATION PASS FROM LABEL 'START'
135 endif
136 START:
137 isfnL = giFileL ;SOURCE SOUND/WAVEFORM FUNCTION TABLE
138 isfnR = giFileR ;SOURCE SOUND/WAVEFORM FUNCTION TABLE
139
140 if i(gksfn)=1 then
141 isfnL = gisine
142 isfnR = isfnL
143 elseif i(gksfn)=2 then
144 isfnL = gibuzz
145 isfnR = isfnL
146 endif
147 iwfn = giwfn1 + i(gkwfn)
148
149 kDensRnd exprand gkDensRnd ;CREATE A RANDOM OFFSET FACTOR THAT WILL BE APPLIED TO FOR DENSITY
150 kdens = kdens * (1 + kDensRnd) ;DENSITY VALUE IS OFFSET BY RANDOM FACTOR
151 imgdur = 1 ;MAXIMUM GRAIN DURATION
152
153 if gksfn=0 then ;IF INPUT TABLE FOR GRAINS IS A SOUND FILE...
154 kpitch = (sr*kratio)/giftlen2
155 else ;OTHERWISE (WAVEFORM)...
156 kpitch = kcps
157 endif
158
159 ;THE AMPLITUDE OFFSET PARAMETER IS MODIFIED TO WHAT I THINK IS A SLIGHTLY MORE USEFUL ARRANGEMENT
160 aSigL grain gkamp, kpitch, kdens, -(gkampoff*gkamp), gkfmd, gkdur, isfnL, iwfn, imgdur , i(gkgrnd)
161 aSigR grain gkamp, kpitch, kdens, -(gkampoff*gkamp), gkfmd, gkdur, isfnR, iwfn, imgdur , i(gkgrnd)
162
163 rireturn ;RETURN TO PERFORMANCE TIME PASSES
164 aenv expsegr 0.0001,i(gkAtt),1,i(gkRel),0.0001 ;CLOUD AMPLITUDE ENVELOPE
165 aSigL = aSigL * aenv ;SCALE AUDIO SIGNAL WITH GUI AMPLITUDE SLIDER AND GRAIN CLOUD ENVELOPE
166 aSigR = aSigR * aenv ;SCALE AUDIO SIGNAL WITH GUI AMPLITUDE SLIDER AND GRAIN CLOUD ENVELOPE
167
168 gaRvbSendL = gaRvbSendL + (aSigL*gkRvbAmt) ;ADD TO REVERB SEND VARIABLE (LEFT CHANNEL)
169 gaRvbSendR = gaRvbSendR + (aSigR*gkRvbAmt) ;ADD TO REVERB SEND VARIABLE (RIGHT CHANNEL)
170 outs aSigL, aSigR ;SEND AUDIO TO OUTPUTS
171 endin
172
173 instr 2 ;REVERB
174 aRvbL,aRvbR reverbsc gaRvbSendL, gaRvbSendR, gkRvbSize, 10000
175 outs aRvbL, aRvbR
176 clear gaRvbSendL, gaRvbSendR
177 endin
178
179 instr 3 ;INIT
180 outvalue "_SetPresetIndex", 0
181 endin
182 </CsInstruments>
183 <CsScore>
184 ;INSTR | START | DURATION
185 i 10 0 3600 ;GUI
186 i 2 0 3600 ;REVERB
187 i 3 0.1 0.01 ;INIT
188 </CsScore>
189 </CsoundSynthesizer>
190
191
192
193 <bsbPanel>
194 <label>Widgets</label>
195 <objectName/>
196 <x>72</x>
197 <y>179</y>
198 <width>1036</width>
199 <height>543</height>
200 <visible>true</visible>
201 <uuid/>
202 <bgcolor mode="background">
203 <r>241</r>
204 <g>226</g>
205 <b>185</b>
206 </bgcolor>
207 <bsbObject version="2" type="BSBLabel">
208 <objectName/>
209 <x>2</x>
210 <y>2</y>
211 <width>1026</width>
212 <height>600</height>
213 <uuid>{aa607456-d368-4d59-8497-d16d608404c3}</uuid>
214 <visible>true</visible>
215 <midichan>0</midichan>
216 <midicc>0</midicc>
217 <label>grain</label>
218 <alignment>center</alignment>
219 <font>Liberation Sans</font>
220 <fontsize>18</fontsize>
221 <precision>3</precision>
222 <color>
223 <r>255</r>
224 <g>255</g>
225 <b>255</b>
226 </color>
227 <bgcolor mode="background">
228 <r>0</r>
229 <g>85</g>
230 <b>0</b>
231 </bgcolor>
232 <bordermode>border</bordermode>
233 <borderradius>5</borderradius>
234 <borderwidth>2</borderwidth>
235 </bsbObject>
236 <bsbObject version="2" type="BSBButton">
237 <objectName/>
238 <x>8</x>
239 <y>8</y>
240 <width>120</width>
241 <height>30</height>
242 <uuid>{55273d97-d39a-441c-8da6-87ea139493b6}</uuid>
243 <visible>true</visible>
244 <midichan>0</midichan>
245 <midicc>0</midicc>
246 <type>event</type>
247 <pressedValue>1.00000000</pressedValue>
248 <stringvalue/>
249 <text> On / Off (MIDI)</text>
250 <image>/</image>
251 <eventLine>i1 0 -1</eventLine>
252 <latch>true</latch>
253 <latched>false</latched>
254 </bsbObject>
255 <bsbObject version="2" type="BSBLabel">
256 <objectName/>
257 <x>8</x>
258 <y>148</y>
259 <width>180</width>
260 <height>26</height>
261 <uuid>{8d67138b-037d-461e-8a25-108f849b03c2}</uuid>
262 <visible>true</visible>
263 <midichan>0</midichan>
264 <midicc>0</midicc>
265 <label>Pitch Ratio (SOUND FILE INPUT)</label>
266 <alignment>left</alignment>
267 <font>Liberation Sans</font>
268 <fontsize>10</fontsize>
269 <precision>3</precision>
270 <color>
271 <r>255</r>
272 <g>255</g>
273 <b>255</b>
274 </color>
275 <bgcolor mode="nobackground">
276 <r>255</r>
277 <g>255</g>
278 <b>255</b>
279 </bgcolor>
280 <bordermode>noborder</bordermode>
281 <borderradius>1</borderradius>
282 <borderwidth>1</borderwidth>
283 </bsbObject>
284 <bsbObject version="2" type="BSBHSlider">
285 <objectName>PitchRatio</objectName>
286 <x>8</x>
287 <y>125</y>
288 <width>500</width>
289 <height>27</height>
290 <uuid>{273087bd-e04a-4975-a3bd-5b0a8b5fd40a}</uuid>
291 <visible>true</visible>
292 <midichan>1</midichan>
293 <midicc>2</midicc>
294 <minimum>0.12500000</minimum>
295 <maximum>4.00000000</maximum>
296 <value>1.00000000</value>
297 <mode>lin</mode>
298 <mouseControl act="jump">continuous</mouseControl>
299 <resolution>-1.00000000</resolution>
300 <randomizable group="0">false</randomizable>
301 </bsbObject>
302 <bsbObject version="2" type="BSBDisplay">
303 <objectName>PitchRatio</objectName>
304 <x>448</x>
305 <y>148</y>
306 <width>60</width>
307 <height>26</height>
308 <uuid>{04617e86-7abe-4120-bb9b-1d6ccd2f0983}</uuid>
309 <visible>true</visible>
310 <midichan>0</midichan>
311 <midicc>0</midicc>
312 <label>1.000</label>
313 <alignment>right</alignment>
314 <font>Liberation Sans</font>
315 <fontsize>9</fontsize>
316 <precision>3</precision>
317 <color>
318 <r>255</r>
319 <g>255</g>
320 <b>255</b>
321 </color>
322 <bgcolor mode="nobackground">
323 <r>255</r>
324 <g>255</g>
325 <b>255</b>
326 </bgcolor>
327 <bordermode>noborder</bordermode>
328 <borderradius>1</borderradius>
329 <borderwidth>1</borderwidth>
330 </bsbObject>
331 <bsbObject version="2" type="BSBButton">
332 <objectName>_Browse</objectName>
333 <x>521</x>
334 <y>62</y>
335 <width>170</width>
336 <height>30</height>
337 <uuid>{1757a18f-b418-4ef1-984d-bdee5e985805}</uuid>
338 <visible>true</visible>
339 <midichan>0</midichan>
340 <midicc>0</midicc>
341 <type>value</type>
342 <pressedValue>1.00000000</pressedValue>
343 <stringvalue>AndItsAll.wav</stringvalue>
344 <text>Browse Audio File</text>
345 <image>/</image>
346 <eventLine/>
347 <latch>false</latch>
348 <latched>false</latched>
349 </bsbObject>
350 <bsbObject version="2" type="BSBLineEdit">
351 <objectName>_Browse</objectName>
352 <x>691</x>
353 <y>63</y>
354 <width>330</width>
355 <height>28</height>
356 <uuid>{804f4f24-03f1-4ac2-8ba2-697f15df06cf}</uuid>
357 <visible>true</visible>
358 <midichan>0</midichan>
359 <midicc>0</midicc>
360 <label>AndItsAll.wav</label>
361 <alignment>left</alignment>
362 <font>Liberation Sans</font>
363 <fontsize>10</fontsize>
364 <precision>3</precision>
365 <color>
366 <r>0</r>
367 <g>0</g>
368 <b>0</b>
369 </color>
370 <bgcolor mode="nobackground">
371 <r>206</r>
372 <g>206</g>
373 <b>206</b>
374 </bgcolor>
375 <background>nobackground</background>
376 </bsbObject>
377 <bsbObject version="2" type="BSBLabel">
378 <objectName/>
379 <x>521</x>
380 <y>41</y>
381 <width>120</width>
382 <height>30</height>
383 <uuid>{a918d231-4dd1-4893-81ef-bf453535bda6}</uuid>
384 <visible>true</visible>
385 <midichan>0</midichan>
386 <midicc>0</midicc>
387 <label>Input File</label>
388 <alignment>left</alignment>
389 <font>Liberation Sans</font>
390 <fontsize>10</fontsize>
391 <precision>3</precision>
392 <color>
393 <r>255</r>
394 <g>255</g>
395 <b>255</b>
396 </color>
397 <bgcolor mode="nobackground">
398 <r>255</r>
399 <g>255</g>
400 <b>255</b>
401 </bgcolor>
402 <bordermode>noborder</bordermode>
403 <borderradius>1</borderradius>
404 <borderwidth>1</borderwidth>
405 </bsbObject>
406 <bsbObject version="2" type="BSBLabel">
407 <objectName/>
408 <x>8</x>
409 <y>106</y>
410 <width>180</width>
411 <height>26</height>
412 <uuid>{93f3e274-799d-49e8-9392-4d8c6ad43ae2}</uuid>
413 <visible>true</visible>
414 <midichan>0</midichan>
415 <midicc>0</midicc>
416 <label>Grain Duration (ms)</label>
417 <alignment>left</alignment>
418 <font>Liberation Sans</font>
419 <fontsize>10</fontsize>
420 <precision>3</precision>
421 <color>
422 <r>255</r>
423 <g>255</g>
424 <b>255</b>
425 </color>
426 <bgcolor mode="nobackground">
427 <r>255</r>
428 <g>255</g>
429 <b>255</b>
430 </bgcolor>
431 <bordermode>noborder</bordermode>
432 <borderradius>1</borderradius>
433 <borderwidth>1</borderwidth>
434 </bsbObject>
435 <bsbObject version="2" type="BSBHSlider">
436 <objectName>GrainDuration</objectName>
437 <x>8</x>
438 <y>83</y>
439 <width>500</width>
440 <height>27</height>
441 <uuid>{89741b38-8333-4828-b8b8-656cff90d564}</uuid>
442 <visible>true</visible>
443 <midichan>1</midichan>
444 <midicc>1</midicc>
445 <minimum>0.00100000</minimum>
446 <maximum>1.00000000</maximum>
447 <value>0.25000000</value>
448 <mode>lin</mode>
449 <mouseControl act="jump">continuous</mouseControl>
450 <resolution>-1.00000000</resolution>
451 <randomizable group="0">false</randomizable>
452 </bsbObject>
453 <bsbObject version="2" type="BSBDisplay">
454 <objectName>GrainDuration</objectName>
455 <x>448</x>
456 <y>106</y>
457 <width>60</width>
458 <height>26</height>
459 <uuid>{d1569d45-d5fa-452c-b69f-0b3e0b47cd01}</uuid>
460 <visible>true</visible>
461 <midichan>0</midichan>
462 <midicc>0</midicc>
463 <label>0.250</label>
464 <alignment>right</alignment>
465 <font>Liberation Sans</font>
466 <fontsize>9</fontsize>
467 <precision>3</precision>
468 <color>
469 <r>255</r>
470 <g>255</g>
471 <b>255</b>
472 </color>
473 <bgcolor mode="nobackground">
474 <r>255</r>
475 <g>255</g>
476 <b>255</b>
477 </bgcolor>
478 <bordermode>noborder</bordermode>
479 <borderradius>1</borderradius>
480 <borderwidth>1</borderwidth>
481 </bsbObject>
482 <bsbObject version="2" type="BSBLabel">
483 <objectName/>
484 <x>8</x>
485 <y>190</y>
486 <width>180</width>
487 <height>26</height>
488 <uuid>{9d200fd9-5a42-4f87-89ab-14ef5ac064ba}</uuid>
489 <visible>true</visible>
490 <midichan>0</midichan>
491 <midicc>0</midicc>
492 <label>Pitch CPS (WAVEFORM INPUT)</label>
493 <alignment>left</alignment>
494 <font>Liberation Sans</font>
495 <fontsize>10</fontsize>
496 <precision>3</precision>
497 <color>
498 <r>255</r>
499 <g>255</g>
500 <b>255</b>
501 </color>
502 <bgcolor mode="nobackground">
503 <r>255</r>
504 <g>255</g>
505 <b>255</b>
506 </bgcolor>
507 <bordermode>noborder</bordermode>
508 <borderradius>1</borderradius>
509 <borderwidth>1</borderwidth>
510 </bsbObject>
511 <bsbObject version="2" type="BSBHSlider">
512 <objectName>PitchCPS</objectName>
513 <x>8</x>
514 <y>167</y>
515 <width>500</width>
516 <height>27</height>
517 <uuid>{ecd7a8b0-5bb3-4479-b692-e56294223499}</uuid>
518 <visible>true</visible>
519 <midichan>1</midichan>
520 <midicc>3</midicc>
521 <minimum>1.00000000</minimum>
522 <maximum>5000.00000000</maximum>
523 <value>261.62554932</value>
524 <mode>lin</mode>
525 <mouseControl act="jump">continuous</mouseControl>
526 <resolution>-1.00000000</resolution>
527 <randomizable group="0">false</randomizable>
528 </bsbObject>
529 <bsbObject version="2" type="BSBDisplay">
530 <objectName>PitchCPS</objectName>
531 <x>448</x>
532 <y>190</y>
533 <width>60</width>
534 <height>26</height>
535 <uuid>{f275c8fd-3605-49e8-9090-67ca5f21a9f6}</uuid>
536 <visible>true</visible>
537 <midichan>0</midichan>
538 <midicc>0</midicc>
539 <label>261.626</label>
540 <alignment>right</alignment>
541 <font>Liberation Sans</font>
542 <fontsize>9</fontsize>
543 <precision>3</precision>
544 <color>
545 <r>255</r>
546 <g>255</g>
547 <b>255</b>
548 </color>
549 <bgcolor mode="nobackground">
550 <r>255</r>
551 <g>255</g>
552 <b>255</b>
553 </bgcolor>
554 <bordermode>noborder</bordermode>
555 <borderradius>1</borderradius>
556 <borderwidth>1</borderwidth>
557 </bsbObject>
558 <bsbObject version="2" type="BSBLabel">
559 <objectName/>
560 <x>8</x>
561 <y>64</y>
562 <width>180</width>
563 <height>26</height>
564 <uuid>{5cde19f3-b356-4945-9c8b-43dd67c604dd}</uuid>
565 <visible>true</visible>
566 <midichan>0</midichan>
567 <midicc>0</midicc>
568 <label>Amplitude</label>
569 <alignment>left</alignment>
570 <font>Liberation Sans</font>
571 <fontsize>10</fontsize>
572 <precision>3</precision>
573 <color>
574 <r>255</r>
575 <g>255</g>
576 <b>255</b>
577 </color>
578 <bgcolor mode="nobackground">
579 <r>255</r>
580 <g>255</g>
581 <b>255</b>
582 </bgcolor>
583 <bordermode>noborder</bordermode>
584 <borderradius>1</borderradius>
585 <borderwidth>1</borderwidth>
586 </bsbObject>
587 <bsbObject version="2" type="BSBHSlider">
588 <objectName>Amplitude</objectName>
589 <x>8</x>
590 <y>41</y>
591 <width>500</width>
592 <height>27</height>
593 <uuid>{d6d73a88-8d82-47de-a067-758f1917a3f2}</uuid>
594 <visible>true</visible>
595 <midichan>0</midichan>
596 <midicc>0</midicc>
597 <minimum>0.00000000</minimum>
598 <maximum>1.00000000</maximum>
599 <value>0.05000000</value>
600 <mode>lin</mode>
601 <mouseControl act="jump">continuous</mouseControl>
602 <resolution>-1.00000000</resolution>
603 <randomizable group="0">false</randomizable>
604 </bsbObject>
605 <bsbObject version="2" type="BSBDisplay">
606 <objectName>Amplitude</objectName>
607 <x>448</x>
608 <y>64</y>
609 <width>60</width>
610 <height>26</height>
611 <uuid>{073ad371-9227-46fa-a005-ac10a210db79}</uuid>
612 <visible>true</visible>
613 <midichan>0</midichan>
614 <midicc>0</midicc>
615 <label>0.050</label>
616 <alignment>right</alignment>
617 <font>Liberation Sans</font>
618 <fontsize>9</fontsize>
619 <precision>3</precision>
620 <color>
621 <r>255</r>
622 <g>255</g>
623 <b>255</b>
624 </color>
625 <bgcolor mode="nobackground">
626 <r>255</r>
627 <g>255</g>
628 <b>255</b>
629 </bgcolor>
630 <bordermode>noborder</bordermode>
631 <borderradius>1</borderradius>
632 <borderwidth>1</borderwidth>
633 </bsbObject>
634 <bsbObject version="2" type="BSBLabel">
635 <objectName/>
636 <x>521</x>
637 <y>318</y>
638 <width>500</width>
639 <height>80</height>
640 <uuid>{b83b9228-3958-46d8-adf5-262b04a121c6}</uuid>
641 <visible>true</visible>
642 <midichan>0</midichan>
643 <midicc>0</midicc>
644 <label>Reverb</label>
645 <alignment>left</alignment>
646 <font>Liberation Sans</font>
647 <fontsize>14</fontsize>
648 <precision>3</precision>
649 <color>
650 <r>255</r>
651 <g>255</g>
652 <b>255</b>
653 </color>
654 <bgcolor mode="nobackground">
655 <r>255</r>
656 <g>255</g>
657 <b>255</b>
658 </bgcolor>
659 <bordermode>border</bordermode>
660 <borderradius>1</borderradius>
661 <borderwidth>1</borderwidth>
662 </bsbObject>
663 <bsbObject version="2" type="BSBLabel">
664 <objectName/>
665 <x>521</x>
666 <y>365</y>
667 <width>180</width>
668 <height>30</height>
669 <uuid>{489dc531-f476-4ca3-b56d-f970ee2c49aa}</uuid>
670 <visible>true</visible>
671 <midichan>0</midichan>
672 <midicc>0</midicc>
673 <label>Level</label>
674 <alignment>left</alignment>
675 <font>Liberation Sans</font>
676 <fontsize>10</fontsize>
677 <precision>3</precision>
678 <color>
679 <r>255</r>
680 <g>255</g>
681 <b>255</b>
682 </color>
683 <bgcolor mode="nobackground">
684 <r>255</r>
685 <g>255</g>
686 <b>255</b>
687 </bgcolor>
688 <bordermode>noborder</bordermode>
689 <borderradius>1</borderradius>
690 <borderwidth>1</borderwidth>
691 </bsbObject>
692 <bsbObject version="2" type="BSBHSlider">
693 <objectName>Level</objectName>
694 <x>521</x>
695 <y>342</y>
696 <width>250</width>
697 <height>27</height>
698 <uuid>{dbdbe7cb-a74d-45b2-9e47-e5c0594f3ea5}</uuid>
699 <visible>true</visible>
700 <midichan>0</midichan>
701 <midicc>0</midicc>
702 <minimum>0.00000000</minimum>
703 <maximum>1.00000000</maximum>
704 <value>0.10000000</value>
705 <mode>lin</mode>
706 <mouseControl act="jump">continuous</mouseControl>
707 <resolution>-1.00000000</resolution>
708 <randomizable group="0">false</randomizable>
709 </bsbObject>
710 <bsbObject version="2" type="BSBDisplay">
711 <objectName>Level</objectName>
712 <x>711</x>
713 <y>365</y>
714 <width>60</width>
715 <height>30</height>
716 <uuid>{2aea18ca-8a9a-457a-8de3-cb7c918a4e3b}</uuid>
717 <visible>true</visible>
718 <midichan>0</midichan>
719 <midicc>0</midicc>
720 <label>0.100</label>
721 <alignment>right</alignment>
722 <font>Liberation Sans</font>
723 <fontsize>9</fontsize>
724 <precision>3</precision>
725 <color>
726 <r>255</r>
727 <g>255</g>
728 <b>255</b>
729 </color>
730 <bgcolor mode="nobackground">
731 <r>255</r>
732 <g>255</g>
733 <b>255</b>
734 </bgcolor>
735 <bordermode>noborder</bordermode>
736 <borderradius>1</borderradius>
737 <borderwidth>1</borderwidth>
738 </bsbObject>
739 <bsbObject version="2" type="BSBDisplay">
740 <objectName>Size</objectName>
741 <x>961</x>
742 <y>365</y>
743 <width>60</width>
744 <height>30</height>
745 <uuid>{ea7f84c3-e2da-4b1c-a79e-61c2a264d20c}</uuid>
746 <visible>true</visible>
747 <midichan>0</midichan>
748 <midicc>0</midicc>
749 <label>0.850</label>
750 <alignment>right</alignment>
751 <font>Liberation Sans</font>
752 <fontsize>9</fontsize>
753 <precision>3</precision>
754 <color>
755 <r>255</r>
756 <g>255</g>
757 <b>255</b>
758 </color>
759 <bgcolor mode="nobackground">
760 <r>255</r>
761 <g>255</g>
762 <b>255</b>
763 </bgcolor>
764 <bordermode>noborder</bordermode>
765 <borderradius>1</borderradius>
766 <borderwidth>1</borderwidth>
767 </bsbObject>
768 <bsbObject version="2" type="BSBHSlider">
769 <objectName>Size</objectName>
770 <x>771</x>
771 <y>342</y>
772 <width>250</width>
773 <height>27</height>
774 <uuid>{cb664a0c-f84b-41f5-92e9-7deb5a672d56}</uuid>
775 <visible>true</visible>
776 <midichan>0</midichan>
777 <midicc>0</midicc>
778 <minimum>0.00000000</minimum>
779 <maximum>1.00000000</maximum>
780 <value>0.85000002</value>
781 <mode>lin</mode>
782 <mouseControl act="jump">continuous</mouseControl>
783 <resolution>-1.00000000</resolution>
784 <randomizable group="0">false</randomizable>
785 </bsbObject>
786 <bsbObject version="2" type="BSBLabel">
787 <objectName/>
788 <x>771</x>
789 <y>365</y>
790 <width>180</width>
791 <height>30</height>
792 <uuid>{7a8b8cb8-12e8-415d-b11c-fb0d460c9e6f}</uuid>
793 <visible>true</visible>
794 <midichan>0</midichan>
795 <midicc>0</midicc>
796 <label>Size</label>
797 <alignment>left</alignment>
798 <font>Liberation Sans</font>
799 <fontsize>10</fontsize>
800 <precision>3</precision>
801 <color>
802 <r>255</r>
803 <g>255</g>
804 <b>255</b>
805 </color>
806 <bgcolor mode="nobackground">
807 <r>255</r>
808 <g>255</g>
809 <b>255</b>
810 </bgcolor>
811 <bordermode>noborder</bordermode>
812 <borderradius>1</borderradius>
813 <borderwidth>1</borderwidth>
814 </bsbObject>
815 <bsbObject version="2" type="BSBLabel">
816 <objectName/>
817 <x>8</x>
818 <y>316</y>
819 <width>220</width>
820 <height>26</height>
821 <uuid>{b6afbe1e-677c-44a6-ba84-4c32dc21b0a7}</uuid>
822 <visible>true</visible>
823 <midichan>0</midichan>
824 <midicc>0</midicc>
825 <label>Density Randomize Amount</label>
826 <alignment>left</alignment>
827 <font>Liberation Sans</font>
828 <fontsize>10</fontsize>
829 <precision>3</precision>
830 <color>
831 <r>255</r>
832 <g>255</g>
833 <b>255</b>
834 </color>
835 <bgcolor mode="nobackground">
836 <r>255</r>
837 <g>255</g>
838 <b>255</b>
839 </bgcolor>
840 <bordermode>noborder</bordermode>
841 <borderradius>1</borderradius>
842 <borderwidth>1</borderwidth>
843 </bsbObject>
844 <bsbObject version="2" type="BSBHSlider">
845 <objectName>DensityRnd</objectName>
846 <x>8</x>
847 <y>293</y>
848 <width>500</width>
849 <height>27</height>
850 <uuid>{859d1ded-b337-4ee7-ac9b-48a1b5f77d16}</uuid>
851 <visible>true</visible>
852 <midichan>0</midichan>
853 <midicc>0</midicc>
854 <minimum>0.00000000</minimum>
855 <maximum>10.00000000</maximum>
856 <value>0.00000000</value>
857 <mode>lin</mode>
858 <mouseControl act="jump">continuous</mouseControl>
859 <resolution>-1.00000000</resolution>
860 <randomizable group="0">false</randomizable>
861 </bsbObject>
862 <bsbObject version="2" type="BSBDisplay">
863 <objectName>DensityRnd</objectName>
864 <x>448</x>
865 <y>316</y>
866 <width>60</width>
867 <height>26</height>
868 <uuid>{95f6cb02-77ec-46fe-876b-a93efac3c5e5}</uuid>
869 <visible>true</visible>
870 <midichan>0</midichan>
871 <midicc>0</midicc>
872 <label>0.000</label>
873 <alignment>right</alignment>
874 <font>Liberation Sans</font>
875 <fontsize>9</fontsize>
876 <precision>3</precision>
877 <color>
878 <r>255</r>
879 <g>255</g>
880 <b>255</b>
881 </color>
882 <bgcolor mode="nobackground">
883 <r>255</r>
884 <g>255</g>
885 <b>255</b>
886 </bgcolor>
887 <bordermode>noborder</bordermode>
888 <borderradius>1</borderradius>
889 <borderwidth>1</borderwidth>
890 </bsbObject>
891 <bsbObject version="2" type="BSBLabel">
892 <objectName/>
893 <x>8</x>
894 <y>274</y>
895 <width>180</width>
896 <height>26</height>
897 <uuid>{7fd47947-fd0d-4964-85e5-682fed1916c7}</uuid>
898 <visible>true</visible>
899 <midichan>0</midichan>
900 <midicc>0</midicc>
901 <label>Density</label>
902 <alignment>left</alignment>
903 <font>Liberation Sans</font>
904 <fontsize>10</fontsize>
905 <precision>3</precision>
906 <color>
907 <r>255</r>
908 <g>255</g>
909 <b>255</b>
910 </color>
911 <bgcolor mode="nobackground">
912 <r>255</r>
913 <g>255</g>
914 <b>255</b>
915 </bgcolor>
916 <bordermode>noborder</bordermode>
917 <borderradius>1</borderradius>
918 <borderwidth>1</borderwidth>
919 </bsbObject>
920 <bsbObject version="2" type="BSBHSlider">
921 <objectName>Density</objectName>
922 <x>8</x>
923 <y>251</y>
924 <width>500</width>
925 <height>27</height>
926 <uuid>{475cdd64-a4ca-4ebc-a000-90448e932478}</uuid>
927 <visible>true</visible>
928 <midichan>1</midichan>
929 <midicc>4</midicc>
930 <minimum>1.00000000</minimum>
931 <maximum>500.00000000</maximum>
932 <value>20.00000000</value>
933 <mode>lin</mode>
934 <mouseControl act="jump">continuous</mouseControl>
935 <resolution>-1.00000000</resolution>
936 <randomizable group="0">false</randomizable>
937 </bsbObject>
938 <bsbObject version="2" type="BSBDisplay">
939 <objectName>Density</objectName>
940 <x>448</x>
941 <y>274</y>
942 <width>60</width>
943 <height>26</height>
944 <uuid>{dc75acc2-c015-4b8d-8fb2-467b9fb96d42}</uuid>
945 <visible>true</visible>
946 <midichan>0</midichan>
947 <midicc>0</midicc>
948 <label>20.000</label>
949 <alignment>right</alignment>
950 <font>Liberation Sans</font>
951 <fontsize>9</fontsize>
952 <precision>3</precision>
953 <color>
954 <r>255</r>
955 <g>255</g>
956 <b>255</b>
957 </color>
958 <bgcolor mode="nobackground">
959 <r>255</r>
960 <g>255</g>
961 <b>255</b>
962 </bgcolor>
963 <bordermode>noborder</bordermode>
964 <borderradius>1</borderradius>
965 <borderwidth>1</borderwidth>
966 </bsbObject>
967 <bsbObject version="2" type="BSBLabel">
968 <objectName/>
969 <x>8</x>
970 <y>232</y>
971 <width>180</width>
972 <height>26</height>
973 <uuid>{3ebc1139-1fdb-48dc-9150-49ee8dfdbd4a}</uuid>
974 <visible>true</visible>
975 <midichan>0</midichan>
976 <midicc>0</midicc>
977 <label>Pitch Randomization</label>
978 <alignment>left</alignment>
979 <font>Liberation Sans</font>
980 <fontsize>10</fontsize>
981 <precision>3</precision>
982 <color>
983 <r>255</r>
984 <g>255</g>
985 <b>255</b>
986 </color>
987 <bgcolor mode="nobackground">
988 <r>255</r>
989 <g>255</g>
990 <b>255</b>
991 </bgcolor>
992 <bordermode>noborder</bordermode>
993 <borderradius>1</borderradius>
994 <borderwidth>1</borderwidth>
995 </bsbObject>
996 <bsbObject version="2" type="BSBHSlider">
997 <objectName>PitchRnd</objectName>
998 <x>8</x>
999 <y>209</y>
1000 <width>500</width>
1001 <height>27</height>
1002 <uuid>{2cf97843-5b49-438e-8034-62a459597e86}</uuid>
1003 <visible>true</visible>
1004 <midichan>0</midichan>
1005 <midicc>0</midicc>
1006 <minimum>0.00000000</minimum>
1007 <maximum>0.30000000</maximum>
1008 <value>0.00000000</value>
1009 <mode>lin</mode>
1010 <mouseControl act="jump">continuous</mouseControl>
1011 <resolution>-1.00000000</resolution>
1012 <randomizable group="0">false</randomizable>
1013 </bsbObject>
1014 <bsbObject version="2" type="BSBDisplay">
1015 <objectName>PitchRnd</objectName>
1016 <x>448</x>
1017 <y>232</y>
1018 <width>60</width>
1019 <height>26</height>
1020 <uuid>{e54486c5-f9aa-4d0e-9a67-6506dae3c790}</uuid>
1021 <visible>true</visible>
1022 <midichan>0</midichan>
1023 <midicc>0</midicc>
1024 <label>0.000</label>
1025 <alignment>right</alignment>
1026 <font>Liberation Sans</font>
1027 <fontsize>9</fontsize>
1028 <precision>3</precision>
1029 <color>
1030 <r>255</r>
1031 <g>255</g>
1032 <b>255</b>
1033 </color>
1034 <bgcolor mode="nobackground">
1035 <r>255</r>
1036 <g>255</g>
1037 <b>255</b>
1038 </bgcolor>
1039 <bordermode>noborder</bordermode>
1040 <borderradius>1</borderradius>
1041 <borderwidth>1</borderwidth>
1042 </bsbObject>
1043 <bsbObject version="2" type="BSBButton">
1044 <objectName>MIDItoPch</objectName>
1045 <x>976</x>
1046 <y>131</y>
1047 <width>16</width>
1048 <height>16</height>
1049 <uuid>{15cb1c0c-7f3b-4f53-93c1-383a67f11366}</uuid>
1050 <visible>true</visible>
1051 <midichan>0</midichan>
1052 <midicc>0</midicc>
1053 <type>value</type>
1054 <pressedValue>1.00000000</pressedValue>
1055 <stringvalue/>
1056 <text/>
1057 <image>/</image>
1058 <eventLine/>
1059 <latch>true</latch>
1060 <latched>false</latched>
1061 </bsbObject>
1062 <bsbObject version="2" type="BSBLabel">
1063 <objectName/>
1064 <x>856</x>
1065 <y>127</y>
1066 <width>120</width>
1067 <height>30</height>
1068 <uuid>{efdeda47-7ac4-4566-8c07-9f1a98886c5e}</uuid>
1069 <visible>true</visible>
1070 <midichan>0</midichan>
1071 <midicc>0</midicc>
1072 <label>MIDI to Pitch</label>
1073 <alignment>right</alignment>
1074 <font>Liberation Sans</font>
1075 <fontsize>10</fontsize>
1076 <precision>3</precision>
1077 <color>
1078 <r>255</r>
1079 <g>255</g>
1080 <b>255</b>
1081 </color>
1082 <bgcolor mode="nobackground">
1083 <r>255</r>
1084 <g>255</g>
1085 <b>255</b>
1086 </bgcolor>
1087 <bordermode>noborder</bordermode>
1088 <borderradius>1</borderradius>
1089 <borderwidth>1</borderwidth>
1090 </bsbObject>
1091 <bsbObject version="2" type="BSBButton">
1092 <objectName>MIDItoDens</objectName>
1093 <x>976</x>
1094 <y>164</y>
1095 <width>16</width>
1096 <height>16</height>
1097 <uuid>{6083872a-d937-4f30-ae49-bc3a1cccab54}</uuid>
1098 <visible>true</visible>
1099 <midichan>0</midichan>
1100 <midicc>0</midicc>
1101 <type>value</type>
1102 <pressedValue>1.00000000</pressedValue>
1103 <stringvalue/>
1104 <text/>
1105 <image>/</image>
1106 <eventLine/>
1107 <latch>true</latch>
1108 <latched>false</latched>
1109 </bsbObject>
1110 <bsbObject version="2" type="BSBLabel">
1111 <objectName/>
1112 <x>856</x>
1113 <y>160</y>
1114 <width>120</width>
1115 <height>30</height>
1116 <uuid>{3e9cc7b4-8f67-4225-813b-1412a0f6f00d}</uuid>
1117 <visible>true</visible>
1118 <midichan>0</midichan>
1119 <midicc>0</midicc>
1120 <label>MIDI to Density</label>
1121 <alignment>right</alignment>
1122 <font>Liberation Sans</font>
1123 <fontsize>10</fontsize>
1124 <precision>3</precision>
1125 <color>
1126 <r>255</r>
1127 <g>255</g>
1128 <b>255</b>
1129 </color>
1130 <bgcolor mode="nobackground">
1131 <r>255</r>
1132 <g>255</g>
1133 <b>255</b>
1134 </bgcolor>
1135 <bordermode>noborder</bordermode>
1136 <borderradius>1</borderradius>
1137 <borderwidth>1</borderwidth>
1138 </bsbObject>
1139 <bsbObject version="2" type="BSBLabel">
1140 <objectName/>
1141 <x>521</x>
1142 <y>164</y>
1143 <width>137</width>
1144 <height>32</height>
1145 <uuid>{48bd216b-d27b-4396-b997-30ddbe53d173}</uuid>
1146 <visible>true</visible>
1147 <midichan>0</midichan>
1148 <midicc>0</midicc>
1149 <label>Grain Envelope Type</label>
1150 <alignment>left</alignment>
1151 <font>Liberation Sans</font>
1152 <fontsize>10</fontsize>
1153 <precision>3</precision>
1154 <color>
1155 <r>255</r>
1156 <g>255</g>
1157 <b>255</b>
1158 </color>
1159 <bgcolor mode="nobackground">
1160 <r>255</r>
1161 <g>255</g>
1162 <b>255</b>
1163 </bgcolor>
1164 <bordermode>noborder</bordermode>
1165 <borderradius>1</borderradius>
1166 <borderwidth>1</borderwidth>
1167 </bsbObject>
1168 <bsbObject version="2" type="BSBLabel">
1169 <objectName/>
1170 <x>521</x>
1171 <y>102</y>
1172 <width>120</width>
1173 <height>30</height>
1174 <uuid>{0b39dee5-918a-4abe-b3be-e15ba5222429}</uuid>
1175 <visible>true</visible>
1176 <midichan>0</midichan>
1177 <midicc>0</midicc>
1178 <label>Input :</label>
1179 <alignment>left</alignment>
1180 <font>Liberation Sans</font>
1181 <fontsize>10</fontsize>
1182 <precision>3</precision>
1183 <color>
1184 <r>255</r>
1185 <g>255</g>
1186 <b>255</b>
1187 </color>
1188 <bgcolor mode="nobackground">
1189 <r>255</r>
1190 <g>255</g>
1191 <b>255</b>
1192 </bgcolor>
1193 <bordermode>noborder</bordermode>
1194 <borderradius>1</borderradius>
1195 <borderwidth>1</borderwidth>
1196 </bsbObject>
1197 <bsbObject version="2" type="BSBLabel">
1198 <objectName/>
1199 <x>8</x>
1200 <y>396</y>
1201 <width>1014</width>
1202 <height>187</height>
1203 <uuid>{9c6abfa6-99bf-4a15-94a4-ce86b18f37d9}</uuid>
1204 <visible>true</visible>
1205 <midichan>0</midichan>
1206 <midicc>0</midicc>
1207 <label>-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1208 'grain' is an opcode for the creation of granular synthesis clouds of sound. 'grain' does not offer precise control of where grains are read from in the source function table as other opcodes do so it is less suited to time stretching or or time compression tasks. Instead the grain pointer is either static or random across the duration of the input table - this option can be defined using the on-screen GUI button. 'grain' works well for granular synthesis based on a single cycle waveforms and in fact 'grain' offers some options not available with 'grain2' or 'grain3' such as amplitude randomness offset. (grain has a different author to grain2 and grain3.) This example implements many of the feature of the grain3 example, the key difference is the inclusion of single cycle waveforms as source inputs (a sine wave and a 'buzz' waveform). If a sound file is chosen as input grain's pitch input is defined using the 'Pitch CPS' slider (or MIDI note if this option has been selected). If a single cycle waveform has been chosen then pitch is define using the 'Pitch Ratio' slider.
1209 Some GUI sliders are also controllable using MIDI controllers. Details are given on the GUI labels.</label>
1210 <alignment>left</alignment>
1211 <font>Liberation Sans</font>
1212 <fontsize>14</fontsize>
1213 <precision>3</precision>
1214 <color>
1215 <r>255</r>
1216 <g>255</g>
1217 <b>255</b>
1218 </color>
1219 <bgcolor mode="nobackground">
1220 <r>255</r>
1221 <g>255</g>
1222 <b>255</b>
1223 </bgcolor>
1224 <bordermode>noborder</bordermode>
1225 <borderradius>1</borderradius>
1226 <borderwidth>1</borderwidth>
1227 </bsbObject>
1228 <bsbObject version="2" type="BSBButton">
1229 <objectName>Pointer</objectName>
1230 <x>850</x>
1231 <y>8</y>
1232 <width>170</width>
1233 <height>30</height>
1234 <uuid>{bc32299e-6430-4d2b-b8fc-ab4eca36f66f}</uuid>
1235 <visible>true</visible>
1236 <midichan>0</midichan>
1237 <midicc>0</midicc>
1238 <type>value</type>
1239 <pressedValue>1.00000000</pressedValue>
1240 <stringvalue/>
1241 <text> Pointer Random/Static</text>
1242 <image>/</image>
1243 <eventLine/>
1244 <latch>true</latch>
1245 <latched>false</latched>
1246 </bsbObject>
1247 <bsbObject version="2" type="BSBLabel">
1248 <objectName/>
1249 <x>188</x>
1250 <y>106</y>
1251 <width>60</width>
1252 <height>26</height>
1253 <uuid>{7e9a1f28-a598-4dd0-8df3-8cf7f4dd4316}</uuid>
1254 <visible>true</visible>
1255 <midichan>0</midichan>
1256 <midicc>0</midicc>
1257 <label>CC#1</label>
1258 <alignment>left</alignment>
1259 <font>Liberation Sans</font>
1260 <fontsize>10</fontsize>
1261 <precision>3</precision>
1262 <color>
1263 <r>255</r>
1264 <g>255</g>
1265 <b>255</b>
1266 </color>
1267 <bgcolor mode="nobackground">
1268 <r>255</r>
1269 <g>255</g>
1270 <b>255</b>
1271 </bgcolor>
1272 <bordermode>noborder</bordermode>
1273 <borderradius>1</borderradius>
1274 <borderwidth>1</borderwidth>
1275 </bsbObject>
1276 <bsbObject version="2" type="BSBLabel">
1277 <objectName/>
1278 <x>188</x>
1279 <y>148</y>
1280 <width>60</width>
1281 <height>26</height>
1282 <uuid>{6725c6e5-73eb-43a9-8f53-64438942c11f}</uuid>
1283 <visible>true</visible>
1284 <midichan>0</midichan>
1285 <midicc>0</midicc>
1286 <label>CC#2</label>
1287 <alignment>left</alignment>
1288 <font>Liberation Sans</font>
1289 <fontsize>10</fontsize>
1290 <precision>3</precision>
1291 <color>
1292 <r>255</r>
1293 <g>255</g>
1294 <b>255</b>
1295 </color>
1296 <bgcolor mode="nobackground">
1297 <r>255</r>
1298 <g>255</g>
1299 <b>255</b>
1300 </bgcolor>
1301 <bordermode>noborder</bordermode>
1302 <borderradius>1</borderradius>
1303 <borderwidth>1</borderwidth>
1304 </bsbObject>
1305 <bsbObject version="2" type="BSBLabel">
1306 <objectName/>
1307 <x>188</x>
1308 <y>190</y>
1309 <width>60</width>
1310 <height>26</height>
1311 <uuid>{0c3d253f-e83e-4b66-b960-9d69b0c27c72}</uuid>
1312 <visible>true</visible>
1313 <midichan>0</midichan>
1314 <midicc>0</midicc>
1315 <label>CC#3</label>
1316 <alignment>left</alignment>
1317 <font>Liberation Sans</font>
1318 <fontsize>10</fontsize>
1319 <precision>3</precision>
1320 <color>
1321 <r>255</r>
1322 <g>255</g>
1323 <b>255</b>
1324 </color>
1325 <bgcolor mode="nobackground">
1326 <r>255</r>
1327 <g>255</g>
1328 <b>255</b>
1329 </bgcolor>
1330 <bordermode>noborder</bordermode>
1331 <borderradius>1</borderradius>
1332 <borderwidth>1</borderwidth>
1333 </bsbObject>
1334 <bsbObject version="2" type="BSBLabel">
1335 <objectName/>
1336 <x>188</x>
1337 <y>274</y>
1338 <width>60</width>
1339 <height>26</height>
1340 <uuid>{20134265-3566-4ded-8967-6e7d4cc607b0}</uuid>
1341 <visible>true</visible>
1342 <midichan>0</midichan>
1343 <midicc>0</midicc>
1344 <label>CC#4</label>
1345 <alignment>left</alignment>
1346 <font>Liberation Sans</font>
1347 <fontsize>10</fontsize>
1348 <precision>3</precision>
1349 <color>
1350 <r>255</r>
1351 <g>255</g>
1352 <b>255</b>
1353 </color>
1354 <bgcolor mode="nobackground">
1355 <r>255</r>
1356 <g>255</g>
1357 <b>255</b>
1358 </bgcolor>
1359 <bordermode>noborder</bordermode>
1360 <borderradius>1</borderradius>
1361 <borderwidth>1</borderwidth>
1362 </bsbObject>
1363 <bsbObject version="2" type="BSBLabel">
1364 <objectName/>
1365 <x>8</x>
1366 <y>358</y>
1367 <width>220</width>
1368 <height>26</height>
1369 <uuid>{f1062244-7bf8-4fe3-bda2-18ee04af46b6}</uuid>
1370 <visible>true</visible>
1371 <midichan>0</midichan>
1372 <midicc>0</midicc>
1373 <label>Amplitude Offset</label>
1374 <alignment>left</alignment>
1375 <font>Liberation Sans</font>
1376 <fontsize>10</fontsize>
1377 <precision>3</precision>
1378 <color>
1379 <r>255</r>
1380 <g>255</g>
1381 <b>255</b>
1382 </color>
1383 <bgcolor mode="nobackground">
1384 <r>255</r>
1385 <g>255</g>
1386 <b>255</b>
1387 </bgcolor>
1388 <bordermode>noborder</bordermode>
1389 <borderradius>1</borderradius>
1390 <borderwidth>1</borderwidth>
1391 </bsbObject>
1392 <bsbObject version="2" type="BSBHSlider">
1393 <objectName>AmpOffset</objectName>
1394 <x>8</x>
1395 <y>335</y>
1396 <width>500</width>
1397 <height>27</height>
1398 <uuid>{697ec088-da4a-4253-915b-08873bdc209f}</uuid>
1399 <visible>true</visible>
1400 <midichan>0</midichan>
1401 <midicc>0</midicc>
1402 <minimum>0.00000000</minimum>
1403 <maximum>1.00000000</maximum>
1404 <value>0.00000000</value>
1405 <mode>lin</mode>
1406 <mouseControl act="jump">continuous</mouseControl>
1407 <resolution>-1.00000000</resolution>
1408 <randomizable group="0">false</randomizable>
1409 </bsbObject>
1410 <bsbObject version="2" type="BSBDisplay">
1411 <objectName>AmpOffset</objectName>
1412 <x>448</x>
1413 <y>358</y>
1414 <width>60</width>
1415 <height>26</height>
1416 <uuid>{0fa1309e-7470-41eb-81d0-846f17bf4040}</uuid>
1417 <visible>true</visible>
1418 <midichan>0</midichan>
1419 <midicc>0</midicc>
1420 <label>0.000</label>
1421 <alignment>right</alignment>
1422 <font>Liberation Sans</font>
1423 <fontsize>9</fontsize>
1424 <precision>3</precision>
1425 <color>
1426 <r>255</r>
1427 <g>255</g>
1428 <b>255</b>
1429 </color>
1430 <bgcolor mode="nobackground">
1431 <r>255</r>
1432 <g>255</g>
1433 <b>255</b>
1434 </bgcolor>
1435 <bordermode>noborder</bordermode>
1436 <borderradius>1</borderradius>
1437 <borderwidth>1</borderwidth>
1438 </bsbObject>
1439 <bsbObject version="2" type="BSBLabel">
1440 <objectName/>
1441 <x>521</x>
1442 <y>228</y>
1443 <width>500</width>
1444 <height>80</height>
1445 <uuid>{05dc69b3-743f-477a-8c4c-d0aa7eb2a3ab}</uuid>
1446 <visible>true</visible>
1447 <midichan>0</midichan>
1448 <midicc>0</midicc>
1449 <label>Grain Cloud Envelope</label>
1450 <alignment>left</alignment>
1451 <font>Liberation Sans</font>
1452 <fontsize>14</fontsize>
1453 <precision>3</precision>
1454 <color>
1455 <r>255</r>
1456 <g>255</g>
1457 <b>255</b>
1458 </color>
1459 <bgcolor mode="nobackground">
1460 <r>255</r>
1461 <g>255</g>
1462 <b>255</b>
1463 </bgcolor>
1464 <bordermode>border</bordermode>
1465 <borderradius>1</borderradius>
1466 <borderwidth>1</borderwidth>
1467 </bsbObject>
1468 <bsbObject version="2" type="BSBLabel">
1469 <objectName/>
1470 <x>521</x>
1471 <y>274</y>
1472 <width>180</width>
1473 <height>30</height>
1474 <uuid>{0a7a76b5-f94c-47d3-ae11-58981317faae}</uuid>
1475 <visible>true</visible>
1476 <midichan>0</midichan>
1477 <midicc>0</midicc>
1478 <label>Attack Time</label>
1479 <alignment>left</alignment>
1480 <font>Liberation Sans</font>
1481 <fontsize>10</fontsize>
1482 <precision>3</precision>
1483 <color>
1484 <r>255</r>
1485 <g>255</g>
1486 <b>255</b>
1487 </color>
1488 <bgcolor mode="nobackground">
1489 <r>255</r>
1490 <g>255</g>
1491 <b>255</b>
1492 </bgcolor>
1493 <bordermode>noborder</bordermode>
1494 <borderradius>1</borderradius>
1495 <borderwidth>1</borderwidth>
1496 </bsbObject>
1497 <bsbObject version="2" type="BSBHSlider">
1498 <objectName>Attack</objectName>
1499 <x>521</x>
1500 <y>251</y>
1501 <width>250</width>
1502 <height>27</height>
1503 <uuid>{f7c05650-28ed-43de-a461-54f33d5b1754}</uuid>
1504 <visible>true</visible>
1505 <midichan>0</midichan>
1506 <midicc>0</midicc>
1507 <minimum>0.05000000</minimum>
1508 <maximum>10.00000000</maximum>
1509 <value>0.05000000</value>
1510 <mode>lin</mode>
1511 <mouseControl act="jump">continuous</mouseControl>
1512 <resolution>-1.00000000</resolution>
1513 <randomizable group="0">false</randomizable>
1514 </bsbObject>
1515 <bsbObject version="2" type="BSBDisplay">
1516 <objectName>Attack</objectName>
1517 <x>711</x>
1518 <y>274</y>
1519 <width>60</width>
1520 <height>30</height>
1521 <uuid>{c40e0ef2-2a36-4832-ac81-28d31fd7c160}</uuid>
1522 <visible>true</visible>
1523 <midichan>0</midichan>
1524 <midicc>0</midicc>
1525 <label>0.050</label>
1526 <alignment>right</alignment>
1527 <font>Liberation Sans</font>
1528 <fontsize>9</fontsize>
1529 <precision>3</precision>
1530 <color>
1531 <r>255</r>
1532 <g>255</g>
1533 <b>255</b>
1534 </color>
1535 <bgcolor mode="nobackground">
1536 <r>255</r>
1537 <g>255</g>
1538 <b>255</b>
1539 </bgcolor>
1540 <bordermode>noborder</bordermode>
1541 <borderradius>1</borderradius>
1542 <borderwidth>1</borderwidth>
1543 </bsbObject>
1544 <bsbObject version="2" type="BSBDisplay">
1545 <objectName>Release</objectName>
1546 <x>961</x>
1547 <y>274</y>
1548 <width>60</width>
1549 <height>30</height>
1550 <uuid>{81aea6c7-1dfc-4dec-81b8-02ab9ff4e256}</uuid>
1551 <visible>true</visible>
1552 <midichan>0</midichan>
1553 <midicc>0</midicc>
1554 <label>0.050</label>
1555 <alignment>right</alignment>
1556 <font>Liberation Sans</font>
1557 <fontsize>9</fontsize>
1558 <precision>3</precision>
1559 <color>
1560 <r>255</r>
1561 <g>255</g>
1562 <b>255</b>
1563 </color>
1564 <bgcolor mode="nobackground">
1565 <r>255</r>
1566 <g>255</g>
1567 <b>255</b>
1568 </bgcolor>
1569 <bordermode>noborder</bordermode>
1570 <borderradius>1</borderradius>
1571 <borderwidth>1</borderwidth>
1572 </bsbObject>
1573 <bsbObject version="2" type="BSBHSlider">
1574 <objectName>Release</objectName>
1575 <x>771</x>
1576 <y>251</y>
1577 <width>250</width>
1578 <height>27</height>
1579 <uuid>{dee81fbc-26d4-499b-a145-6c4a621f37f4}</uuid>
1580 <visible>true</visible>
1581 <midichan>0</midichan>
1582 <midicc>0</midicc>
1583 <minimum>0.05000000</minimum>
1584 <maximum>10.00000000</maximum>
1585 <value>0.05000000</value>
1586 <mode>lin</mode>
1587 <mouseControl act="jump">continuous</mouseControl>
1588 <resolution>-1.00000000</resolution>
1589 <randomizable group="0">false</randomizable>
1590 </bsbObject>
1591 <bsbObject version="2" type="BSBLabel">
1592 <objectName/>
1593 <x>771</x>
1594 <y>274</y>
1595 <width>180</width>
1596 <height>30</height>
1597 <uuid>{260b7b7f-6914-4c31-8a6f-69dcceac9db2}</uuid>
1598 <visible>true</visible>
1599 <midichan>0</midichan>
1600 <midicc>0</midicc>
1601 <label>Release Time</label>
1602 <alignment>left</alignment>
1603 <font>Liberation Sans</font>
1604 <fontsize>10</fontsize>
1605 <precision>3</precision>
1606 <color>
1607 <r>255</r>
1608 <g>255</g>
1609 <b>255</b>
1610 </color>
1611 <bgcolor mode="nobackground">
1612 <r>255</r>
1613 <g>255</g>
1614 <b>255</b>
1615 </bgcolor>
1616 <bordermode>noborder</bordermode>
1617 <borderradius>1</borderradius>
1618 <borderwidth>1</borderwidth>
1619 </bsbObject>
1620 <bsbObject version="2" type="BSBDropdown">
1621 <objectName>Input</objectName>
1622 <x>521</x>
1623 <y>122</y>
1624 <width>170</width>
1625 <height>30</height>
1626 <uuid>{3d74c37c-0ed0-4274-b87a-89e80608d9c7}</uuid>
1627 <visible>true</visible>
1628 <midichan>0</midichan>
1629 <midicc>0</midicc>
1630 <bsbDropdownItemList>
1631 <bsbDropdownItem>
1632 <name>Sound File</name>
1633 <value>0</value>
1634 <stringvalue/>
1635 </bsbDropdownItem>
1636 <bsbDropdownItem>
1637 <name>Sine</name>
1638 <value>1</value>
1639 <stringvalue/>
1640 </bsbDropdownItem>
1641 <bsbDropdownItem>
1642 <name>Buzz</name>
1643 <value>2</value>
1644 <stringvalue/>
1645 </bsbDropdownItem>
1646 </bsbDropdownItemList>
1647 <selectedIndex>0</selectedIndex>
1648 <randomizable group="0">false</randomizable>
1649 </bsbObject>
1650 <bsbObject version="2" type="BSBDropdown">
1651 <objectName>GrainEnvelope</objectName>
1652 <x>521</x>
1653 <y>185</y>
1654 <width>330</width>
1655 <height>30</height>
1656 <uuid>{a77af4e0-33dd-453b-a8a5-f651f099be25}</uuid>
1657 <visible>true</visible>
1658 <midichan>0</midichan>
1659 <midicc>0</midicc>
1660 <bsbDropdownItemList>
1661 <bsbDropdownItem>
1662 <name>Hanning</name>
1663 <value>0</value>
1664 <stringvalue/>
1665 </bsbDropdownItem>
1666 <bsbDropdownItem>
1667 <name>Percussive (straight segments)</name>
1668 <value>1</value>
1669 <stringvalue/>
1670 </bsbDropdownItem>
1671 <bsbDropdownItem>
1672 <name>Percussive (exponential segments)</name>
1673 <value>2</value>
1674 <stringvalue/>
1675 </bsbDropdownItem>
1676 <bsbDropdownItem>
1677 <name>Gate (with anti click ramp up and ramp down)</name>
1678 <value>3</value>
1679 <stringvalue/>
1680 </bsbDropdownItem>
1681 <bsbDropdownItem>
1682 <name>Reverse Percussive (straight segments)</name>
1683 <value>4</value>
1684 <stringvalue/>
1685 </bsbDropdownItem>
1686 <bsbDropdownItem>
1687 <name>Reverse Percussive (exponential segments)</name>
1688 <value>5</value>
1689 <stringvalue/>
1690 </bsbDropdownItem>
1691 </bsbDropdownItemList>
1692 <selectedIndex>0</selectedIndex>
1693 <randomizable group="0">false</randomizable>
1694 </bsbObject>
1695 </bsbPanel>
1696 <bsbPresets>
1697 <preset name="INIT" number="0" >
1698 <value id="{55273d97-d39a-441c-8da6-87ea139493b6}" mode="1" >0.00000000</value>
1699 <value id="{55273d97-d39a-441c-8da6-87ea139493b6}" mode="4" >0</value>
1700 <value id="{273087bd-e04a-4975-a3bd-5b0a8b5fd40a}" mode="1" >1.00000000</value>
1701 <value id="{04617e86-7abe-4120-bb9b-1d6ccd2f0983}" mode="1" >1.00000000</value>
1702 <value id="{04617e86-7abe-4120-bb9b-1d6ccd2f0983}" mode="4" >1.000</value>
1703 <value id="{1757a18f-b418-4ef1-984d-bdee5e985805}" mode="4" >AndItsAll.wav</value>
1704 <value id="{804f4f24-03f1-4ac2-8ba2-697f15df06cf}" mode="4" >AndItsAll.wav</value>
1705 <value id="{89741b38-8333-4828-b8b8-656cff90d564}" mode="1" >0.25000000</value>
1706 <value id="{d1569d45-d5fa-452c-b69f-0b3e0b47cd01}" mode="1" >0.25000000</value>
1707 <value id="{d1569d45-d5fa-452c-b69f-0b3e0b47cd01}" mode="4" >0.250</value>
1708 <value id="{ecd7a8b0-5bb3-4479-b692-e56294223499}" mode="1" >261.62554932</value>
1709 <value id="{f275c8fd-3605-49e8-9090-67ca5f21a9f6}" mode="1" >261.62600708</value>
1710 <value id="{f275c8fd-3605-49e8-9090-67ca5f21a9f6}" mode="4" >261.626</value>
1711 <value id="{d6d73a88-8d82-47de-a067-758f1917a3f2}" mode="1" >0.05000000</value>
1712 <value id="{073ad371-9227-46fa-a005-ac10a210db79}" mode="1" >0.05000000</value>
1713 <value id="{073ad371-9227-46fa-a005-ac10a210db79}" mode="4" >0.050</value>
1714 <value id="{dbdbe7cb-a74d-45b2-9e47-e5c0594f3ea5}" mode="1" >0.10000000</value>
1715 <value id="{2aea18ca-8a9a-457a-8de3-cb7c918a4e3b}" mode="1" >0.10000000</value>
1716 <value id="{2aea18ca-8a9a-457a-8de3-cb7c918a4e3b}" mode="4" >0.100</value>
1717 <value id="{ea7f84c3-e2da-4b1c-a79e-61c2a264d20c}" mode="1" >0.85000002</value>
1718 <value id="{ea7f84c3-e2da-4b1c-a79e-61c2a264d20c}" mode="4" >0.850</value>
1719 <value id="{cb664a0c-f84b-41f5-92e9-7deb5a672d56}" mode="1" >0.85000002</value>
1720 <value id="{859d1ded-b337-4ee7-ac9b-48a1b5f77d16}" mode="1" >0.00000000</value>
1721 <value id="{95f6cb02-77ec-46fe-876b-a93efac3c5e5}" mode="1" >0.00000000</value>
1722 <value id="{95f6cb02-77ec-46fe-876b-a93efac3c5e5}" mode="4" >0.000</value>
1723 <value id="{475cdd64-a4ca-4ebc-a000-90448e932478}" mode="1" >20.00000000</value>
1724 <value id="{dc75acc2-c015-4b8d-8fb2-467b9fb96d42}" mode="1" >20.00000000</value>
1725 <value id="{dc75acc2-c015-4b8d-8fb2-467b9fb96d42}" mode="4" >20.000</value>
1726 <value id="{2cf97843-5b49-438e-8034-62a459597e86}" mode="1" >0.00000000</value>
1727 <value id="{e54486c5-f9aa-4d0e-9a67-6506dae3c790}" mode="1" >0.00000000</value>
1728 <value id="{e54486c5-f9aa-4d0e-9a67-6506dae3c790}" mode="4" >0.000</value>
1729 <value id="{15cb1c0c-7f3b-4f53-93c1-383a67f11366}" mode="1" >0.00000000</value>
1730 <value id="{15cb1c0c-7f3b-4f53-93c1-383a67f11366}" mode="4" >0</value>
1731 <value id="{6083872a-d937-4f30-ae49-bc3a1cccab54}" mode="1" >0.00000000</value>
1732 <value id="{6083872a-d937-4f30-ae49-bc3a1cccab54}" mode="4" >0</value>
1733 <value id="{bc32299e-6430-4d2b-b8fc-ab4eca36f66f}" mode="1" >0.00000000</value>
1734 <value id="{bc32299e-6430-4d2b-b8fc-ab4eca36f66f}" mode="4" >0</value>
1735 <value id="{697ec088-da4a-4253-915b-08873bdc209f}" mode="1" >0.00000000</value>
1736 <value id="{0fa1309e-7470-41eb-81d0-846f17bf4040}" mode="1" >0.00000000</value>
1737 <value id="{0fa1309e-7470-41eb-81d0-846f17bf4040}" mode="4" >0.000</value>
1738 <value id="{f7c05650-28ed-43de-a461-54f33d5b1754}" mode="1" >0.05000000</value>
1739 <value id="{c40e0ef2-2a36-4832-ac81-28d31fd7c160}" mode="1" >0.05000000</value>
1740 <value id="{c40e0ef2-2a36-4832-ac81-28d31fd7c160}" mode="4" >0.050</value>
1741 <value id="{81aea6c7-1dfc-4dec-81b8-02ab9ff4e256}" mode="1" >0.05000000</value>
1742 <value id="{81aea6c7-1dfc-4dec-81b8-02ab9ff4e256}" mode="4" >0.050</value>
1743 <value id="{dee81fbc-26d4-499b-a145-6c4a621f37f4}" mode="1" >0.05000000</value>
1744 <value id="{3d74c37c-0ed0-4274-b87a-89e80608d9c7}" mode="1" >0.00000000</value>
1745 <value id="{a77af4e0-33dd-453b-a8a5-f651f099be25}" mode="1" >0.00000000</value>
1746 </preset>
1747 </bsbPresets>
1748 <EventPanel name="" tempo="60.00000000" loop="8.00000000" x="913" y="162" width="655" height="346" visible="false" loopStart="0" loopEnd="0"> </EventPanel>