Skip to content

Commit 42770cb

Browse files
committed
Add directory method to StkShakers
1 parent ba941d7 commit 42770cb

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

source/StkUGens/sc/STKclassdefs.sc

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,46 @@ StkSaxofony : UGen {
4949
}
5050

5151
StkShakers : UGen {
52+
classvar shakerTypes;
53+
54+
*initClass {
55+
shakerTypes = Dictionary[
56+
"Maraca" -> 0,
57+
"Cabasa" -> 1,
58+
"Sekere" -> 2,
59+
"Guiro" -> 3,
60+
"Water Drops" -> 4,
61+
"Bamboo Chimes" -> 5,
62+
"Tambourine" -> 6,
63+
"Sleigh Bells" -> 7,
64+
"Sticks" -> 8,
65+
"Crunch" -> 9,
66+
"Wrench" -> 10,
67+
"Sand Paper" -> 11,
68+
"Coke Can" -> 12,
69+
"Next Mug" -> 13,
70+
"Penny + Mug" -> 14,
71+
"Nickle + Mug" -> 15, // Mispelling of "Nickel" in original STK docs
72+
"Dime + Mug" -> 16,
73+
"Quarter + Mug" -> 17,
74+
"Franc + Mug" -> 18,
75+
"Peso + Mug" -> 19,
76+
"Big Rocks" -> 20,
77+
"Little Rocks" -> 21,
78+
"Tuned Bamboo Chimes" -> 21
79+
].freeze;
80+
}
81+
5282
*ar { arg instr=0, energy=64, decay=64, objects=64, resfreq=64, mul = 1.0, add = 0.0;
5383
^this.multiNew('audio',instr, energy, decay, objects, resfreq).madd(mul, add)
5484
}
5585
*kr { arg instr=0, energy=64, decay=64, objects=64, resfreq=64, mul = 1.0, add = 0.0;
5686
^this.multiNew('control', instr, energy, decay, objects, resfreq ).madd(mul, add)
5787
}
88+
89+
*directory {
90+
^shakerTypes
91+
}
5892
}
5993

6094

0 commit comments

Comments
 (0)