-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLeslie Emulator.effect
More file actions
224 lines (197 loc) · 7.34 KB
/
Copy pathLeslie Emulator.effect
File metadata and controls
224 lines (197 loc) · 7.34 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
<effect>
<name>Leslie Emulation</name>
<enabled>true</enabled>
<numIns>2</numIns>
<numOuts>2</numOuts>
<code>if (<LeslieON> == 1) then
ain = ain1 + ain2 ; make mono
awetL, awetR leslieEmulation ain, <Leslie_SPEED>
aout1 = (ain1 * <Leslie_dry>) + (awetL * (1 - <Leslie_dry>))
aout2 = (ain2 * <Leslie_dry>) + (awetR * (1 - <Leslie_dry>))
; ain1 *= <dry> ;dry signal
; ain2 *= <dry>
;
; aout1 = ain1 + awetL ;dry and wet to output
; aout2 = ain2 + awetR ;dry signal
else
aout1 = ain1
aout2 = ain2
endif
</code>
<comments>
DESCRIPTION:
Based on Hans Mikelson's Leslie Emulation
CONTROLLERS:
ON/OFF - bypass
speed - speed of leslie modulation wheel
mix - mix direct signal with effect
---
version 1.11, May 2020
- added comments on controllers
version 1.1, 2015
- new GUI and small code adaptations by Menno Knevel
version 1.0, 2010
- initial version by Steven Yi
</comments>
<opcodeList>
<udo>
<opcodeName>leslieEmulation</opcodeName>
<outTypes>aa</outTypes>
<inTypes>ak</inTypes>
<codeBody>asig, kspeed xin
isine chnget "leslie_sine"
ifilter1 chnget "leslie_filter1"
ifilter2 chnget "leslie_filter2"
idistort chnget "leslie_distort"
if (isine == 0) then
isine ftgentmp 0, 0, 1024, 10, 1
ifilter1 ftgentmp 0, 0, 256, 7, 0, 110, .3, 18, 1, 18, .3, 110, 0
ifilter2 ftgentmp 0, 0, 256, 7, 0, 80, .5, 16, 1, 64, 1, 16, .5, 80, 0
idistort ftgentmp 0, 0, 1024, 8, -.8, 42, -.78, 100, -.7, 740, .7, 100, .78, 42, .8
chnset isine, "leslie_sine"
chnset ifilter1, "leslie_filter1"
chnset ifilter2, "leslie_filter2"
chnset idistort, "leslie_distort"
endif
isep = .2
; DISTORTION EFFECT
asig = asig/40000
aclip tablei asig, idistort, 1, .5
aclip = aclip*30000
aleslie delayr .02, 1
; ACCELERATION
kenv linseg p4, p3+.02, p5
; DOPPLER EFFECT
koscl oscil 1, kspeed, isine, 0
koscr oscil 1, kspeed, isine, isep
kdopl = .01-koscl*.0002
kdopr = .012-koscr*.0002
aleft deltapi kdopl
aright deltapi kdopr
delayw aclip
; FILTER EFFECT
; DIVIDE INTO THREE FREQUENCY RANGES FOR DIRECTIONAL SOUND.
; HIGH PASS
alfhi atone aleft, 8000
arfhi atone aright, 8000
alfhi tone alfhi, 12000
arfhi tone arfhi, 12000
; BAND PASS
alfmid atone aleft, 4000
arfmid atone aright, 4000
alfmid tone alfmid, 8000
arfmid tone arfmid, 8000
; LOW PASS
alflow tone aleft, 4000
arflow tone aright, 4000
kflohi oscil 1, kspeed, ifilter1, 0
kfrohi oscil 1, kspeed, ifilter1, isep
kflomid oscil 1, kspeed, ifilter2, 0
kfromid oscil 1, kspeed, ifilter2, isep
; AMPLITUDE EFFECT
kalosc = koscl * .1 + 1
karosc = koscr * .1 + 1
xout alfhi*kflohi+alfmid*kflomid+alflow*kalosc,arfhi*kfrohi+arfmid*kfromid+arflow*karosc</codeBody>
<comments></comments>
</udo>
</opcodeList>
<graphicInterface editEnabled='true'>
<gridSettings>
<width>5</width>
<height>5</height>
<gridStyle>LINE</gridStyle>
<snapGridEnabled>true</snapGridEnabled>
</gridSettings>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBGroup'>
<objectName></objectName>
<x>0</x>
<y>0</y>
<groupName>Group</groupName>
<backgroundColor>0x00000033</backgroundColor>
<borderColor>0x000000ff</borderColor>
<labelTextColor>0xffffffff</labelTextColor>
<titleEnabled>true</titleEnabled>
<width>20</width>
<height>20</height>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBCheckBox'>
<objectName>LeslieON</objectName>
<x>0</x>
<y>0</y>
<automationAllowed>true</automationAllowed>
<label/>
<selected>true</selected>
<randomizable>true</randomizable>
</bsbObject>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBGroup'>
<objectName></objectName>
<x>10</x>
<y>10</y>
<groupName>Group</groupName>
<backgroundColor>0x4d8080ff</backgroundColor>
<borderColor>0x000000ff</borderColor>
<labelTextColor>0xffffffff</labelTextColor>
<titleEnabled>false</titleEnabled>
<width>70</width>
<height>20</height>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBVSlider' version='2'>
<objectName>Leslie_dry</objectName>
<x>60</x>
<y>25</y>
<automationAllowed>true</automationAllowed>
<minimum>0.0</minimum>
<maximum>1.5</maximum>
<bdresolution>0.01</bdresolution>
<value>1.04</value>
<sliderHeight>50</sliderHeight>
<randomizable>true</randomizable>
<valueDisplayEnabled>false</valueDisplayEnabled>
</bsbObject>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBKnob' version='2'>
<objectName>Leslie_SPEED</objectName>
<x>15</x>
<y>10</y>
<automationAllowed>true</automationAllowed>
<minimum>0.0</minimum>
<maximum>20.0</maximum>
<value>4.19996</value>
<knobWidth>40</knobWidth>
<randomizable>true</randomizable>
<valueDisplayEnabled>true</valueDisplayEnabled>
<label>speed</label>
<labelEnabled>true</labelEnabled>
<font>
<name>System Regular</name>
<size>12.0</size>
</font>
</bsbObject>
<bsbObject type='blue.orchestra.blueSynthBuilder.BSBLabel' version='2'>
<objectName></objectName>
<x>65</x>
<y>10</y>
<label>dry</label>
<font>
<name>System Regular</name>
<size>12.0</size>
</font>
</bsbObject>
</bsbObject>
</bsbObject>
</graphicInterface>
<parameterList>
<parameter uniqueId='172822903' name='Leslie_SPEED' label='' min='0.0' max='20.0' bdresolution='-1' automationEnabled='false' value='4.19996'>
<line name='' version='2' max='20.0' min='0.0' bdresolution='-1' color='-8355712' rightBound='false' endPointsLinked='false'>
<linePoint x='0.0' y='4.19996'/>
</line>
</parameter>
<parameter uniqueId='-604080746' name='Leslie_dry' label='' min='0.0' max='1.5' bdresolution='0.01' automationEnabled='false' value='1.04'>
<line name='' version='2' max='1.5' min='0.0' bdresolution='0.01' color='-8355712' rightBound='false' endPointsLinked='false'>
<linePoint x='0.0' y='1.04'/>
</line>
</parameter>
<parameter uniqueId='-104104227' name='LeslieON' label='' min='0.0' max='1.0' bdresolution='1' automationEnabled='false' value='1.0'>
<line name='' version='2' max='1.0' min='0.0' bdresolution='1' color='-8355712' rightBound='false' endPointsLinked='false'>
<linePoint x='0.0' y='1.0'/>
</line>
</parameter>
</parameterList>
</effect>