]> git.immae.eu Git - perso/Immae/Projets/Python/MusicSampler.git/blame - config.yml
Fix crash when click on unconfigured key
[perso/Immae/Projets/Python/MusicSampler.git] / config.yml
CommitLineData
16847231
IB
1#################################
2##### General configuration #####
3## Keep in mind that in-line option override these
4
5#option listed here are the default options.
6config:
7# debug info
8 debug: false
9# languages. Available: fr, en
10 language: fr
11# path to the musics.
12 music_path: .
13# The awful red message that shows up when you lose the focus
14 focus_warning: true
4094ae4e 15# built-in mixing, try this if your system can't mix the musics by itself
3a488f9f 16 builtin_mixing: false
16847231
IB
17# Device used for playing musics. Default value depends on your system
18# device:
19# Advanced parameters: use at your own risk! (your computer probably won't explode, though)
20 latency: high
21 blocksize: 0
22 frame_rate: 44100
23 sample_width: 2
24 channels: 2
25
26
27
28
85fdcdb7
IB
29###################
30##### Aliases #####
31
8f88a3e4 32aliases:
85fdcdb7
IB
33# for files
34 music1:
35 file: "short_blues.mp3"
36 music2:
37 file: "to_the_Fantasy_war.mp3"
38 noise:
39 file: "croco.mp3"
40# aliases for colors
41 blue:
42 color: [50, 50, 255]
43 orange:
44 color: [255, 126, 0]
45 yellow:
46 color: [250, 250, 0]
47 red:
48 color: [255, 20, 20]
49 light_blue:
50 color: [100, 150, 255]
51 green:
52 color: [50, 180, 50]
53 light_green:
54 color: [150, 255, 100]
55 purple:
16759756 56 color: [190, 110, 236]
85fdcdb7
IB
57 pink:
58 color: [255, 50, 255]
16759756 59
85fdcdb7
IB
60####################################################
61##### Music properties: name and general gain ######
87f211fb
IB
62
63music_properties:
85fdcdb7
IB
64 "short_blues.mp3":
65 name: Short Blues (music 1)
66 "to_the_Fantasy_war.mp3":
67 name: To the Fantasy War (music 2)
68 "croco.mp3":
69 name: Crocodile noise
16759756 70 gain: 1.2
85fdcdb7 71
16847231
IB
72###############################################################################
73##### Key properties: how do the key look like, and some other properties #####
b86db9f1
IB
74
75key_properties:
4094ae4e
IB
76 'common':
77 repeat_delay: 1
b86db9f1
IB
78 'a':
79 description:
16759756 80 -
85fdcdb7
IB
81 - Music 1
82 include: light_blue
b86db9f1
IB
83 'z':
84 description:
85fdcdb7
IB
85 -
86 - Music 2
87 include: light_blue
b86db9f1
IB
88 'e':
89 description:
85fdcdb7
IB
90 -
91 - Noise
92 include: light_blue
b86db9f1
IB
93 't':
94 description:
85fdcdb7
IB
95 -
96 - Crossfade
97 - music 2
98 include: green
99 repeat_delay: 5
b86db9f1
IB
100 'y':
101 description:
85fdcdb7
IB
102 -
103 - Stop wait
104 - music 2
105 include: green
b86db9f1
IB
106 'u':
107 description:
85fdcdb7
IB
108 -
109 - Noise
110 - + Music 2
111 include: green
112
113 'g':
b86db9f1 114 description:
85fdcdb7
IB
115 -
116 - Music 1
117 - Seek 30/60
118 include: purple
119
120 'i':
b86db9f1 121 description:
85fdcdb7
IB
122 -
123 - Noise
124 - +low vol
125 include: green
126
127 'h':
b86db9f1 128 description:
85fdcdb7
IB
129 -
130 - Noise
131 - 3 times
132 include: purple
133 repeat_delay: 2
134
135 'm':
b86db9f1 136 description:
85fdcdb7
IB
137 -
138 - Musics
139 - 1 & 2
140 include: purple
141
142 'n':
b86db9f1 143 description:
85fdcdb7
IB
144 -
145 - Low vol
146 - Up vol
147 include: green
148
149 'home':
b86db9f1 150 description:
85fdcdb7
IB
151 -
152 - vlc
153 include: orange
154
155
156## Some general useful keys
157
158 'ESC':
b86db9f1 159 description:
85fdcdb7
IB
160 - "!"
161 - STOP!
162 include: red
163
164 'F5':
b86db9f1 165 description:
85fdcdb7
IB
166 - "||"
167 - PAUSE
168 include: light_green
169
170 'F6':
b86db9f1 171 description:
85fdcdb7
IB
172 - ">"
173 - UNPAUSE
174 include: light_green
175
176 'F1':
b86db9f1 177 description:
16759756 178 -
85fdcdb7
IB
179 - Stop
180 - fade
181 include: orange
182
183 'F2':
b86db9f1 184 description:
16759756 185 -
85fdcdb7
IB
186 - Stop
187 - actions
188 include: orange
189
190 'F4':
b86db9f1 191 description:
85fdcdb7
IB
192 -
193 - Skip
194 - wait
195 include: pink
196
197 'F12':
b58b8220
IB
198 description:
199 -
85fdcdb7
IB
200 - vol+
201 include: yellow
b58b8220 202
85fdcdb7 203 'F11':
b58b8220 204 description:
85fdcdb7
IB
205 -
206 - "vol-"
207 include: yellow
b58b8220 208
85fdcdb7 209 'right':
b58b8220 210 description:
85fdcdb7
IB
211 -
212 - +10s
213 include: blue
b86db9f1 214
85fdcdb7 215 'left':
16759756 216 description:
85fdcdb7
IB
217 -
218 - -10s
219 include: blue
16759756 220
85fdcdb7
IB
221#################################################################
222##### Keys: what do the key actually do when you press them #####
8f88a3e4
IB
223
224keys:
85fdcdb7 225# Play the songs
8f88a3e4
IB
226 'a':
227 - play:
85fdcdb7 228 include: music1
8f88a3e4 229 'z':
b86db9f1 230 - play:
85fdcdb7 231 include: music2
b86db9f1 232 'e':
b86db9f1 233 - play:
85fdcdb7
IB
234 include: noise
235
236# Crossfade from any music to music 2
b86db9f1 237 't':
8f88a3e4 238 - stop:
b86db9f1 239 fade_out: 5
0e5d59f7 240 - play:
85fdcdb7
IB
241 include: music2
242 fade_in: 5
87f211fb 243
85fdcdb7
IB
244# Fade out, then wait and start music 2
245 'y':
246 - stop:
b86db9f1 247 fade_out: 3
85fdcdb7
IB
248 wait: true
249 set_wait_id: y1
b86db9f1 250 - wait:
85fdcdb7
IB
251 duration: 3
252 set_wait_id: y2
253 - play:
254 include: music2
255
256# Play the noise, stop music 1, wait a bit then start music 2
257 'u':
b58b8220 258 - play:
85fdcdb7 259 include: noise
b58b8220 260 - wait:
85fdcdb7 261 duration: 0.2
b86db9f1 262 - stop:
85fdcdb7
IB
263 include: music1
264 - wait:
265 duration: 3
266 set_wait_id: u
267 - play:
268 include: music2
b58b8220 269
85fdcdb7
IB
270# Play music 1, starting at 30 seconds then seeks at 60 after 5 seconds
271 'g':
272 - play:
273 include: music1
274 start_at: 30
275 - wait:
276 duration: 5
277 set_wait_id: g
278 - seek:
279 include: music1
280 delta: false
281 value: 60
282
283# Play music 1 and 2, after stopping all musics with a fade_out (and wait for this fade out)
b86db9f1
IB
284 'm':
285 - stop:
85fdcdb7
IB
286 fade_out: 2
287 wait: true
b86db9f1 288 - play:
85fdcdb7 289 include: music1
b86db9f1 290 - wait:
85fdcdb7
IB
291 include: music1
292 set_wait_id: m
b86db9f1 293 - play:
85fdcdb7
IB
294 include: music2
295
296# Lowers the volume of music 1 and 2 (if playing), during the duration of noise + 1 second
297 'i':
298 - volume:
299 include: music1
300 value: 50
301 - volume:
302 include: music2
303 value: 50
16759756 304 - play:
85fdcdb7 305 include: noise
16759756 306 - wait:
85fdcdb7
IB
307 include: noise
308 duration: 1
309 set_wait_id: i
16759756 310 - volume:
85fdcdb7
IB
311 include: music1
312 value: 100
313 fade: 1
16759756 314 - volume:
85fdcdb7
IB
315 include: music2
316 value: 100
317 fade: 1
318
319# Lowers the volume of music 1 and 2 (if playing) down to 10% with a 5 seconds fade, then back to 100%
320 'n' :
16759756 321 - volume:
85fdcdb7
IB
322 include: music1
323 value: 10
324 fade: 5
325 - volume:
326 include: music2
327 value: 10
328 fade: 5
16759756 329 - wait:
85fdcdb7
IB
330 duration: 5
331 set_wait_id: n
16759756 332 - volume:
85fdcdb7
IB
333 include: music1
334 value: 100
335 fade: 5
336 - volume:
337 include: music2
338 value: 100
339 fade: 5
16759756 340
85fdcdb7
IB
341# Stops all musics, then plays noise repeated twice (3 times)
342 'h':
343 - stop:
344 fade_out: 0.5
345 - play:
346 include: noise
347 loop: 2
348
349 'home':
350 - run_command:
351 command: vlc *.mp3
352 wait: true
16759756
IB
353
354
85fdcdb7
IB
355##### Useful keys (good to have them all the time)
356
357# Emergency stop!
8f88a3e4 358 'ESC':
85fdcdb7
IB
359 - stop_all_actions:
360 other_only: true
361 - stop:
b86db9f1 362
b58b8220 363
b58b8220 364
85fdcdb7
IB
365# Pause and unpause
366 'F5':
367 - pause:
368
369 'F6':
370 - unpause:
371
372# Stopping all musics, with a short fade (sounds natural)
373 'F1':
16759756
IB
374 - stop:
375 fade_out: 1
376
85fdcdb7
IB
377# Stopping all actions
378 'F2':
379 - stop_all_actions:
380
381# Skip wait
382 'F4':
383 - interrupt_wait:
384 wait_id: n
385 - interrupt_wait:
386 wait_id: m
387 - interrupt_wait:
388 wait_id: i
389 - interrupt_wait:
390 wait_id: y1
391 - interrupt_wait:
392 wait_id: y2
393 - interrupt_wait:
394 wait_id: u
395 - interrupt_wait:
396 wait_id: g
397
398
399# Changing volume
400 'F12':
401 - volume:
402 delta: true
403 value: +10
404 fade: 0.5
405
406 'F11':
407 - volume:
408 delta: true
409 value: -10
410 fade: 0.5
411
412
413# Seek +- 10 seconds
414 'right':
415 - seek:
416 value: 10
417 delta: true
418
419 'left':
420 - seek:
421 value: -10
422 delta: true
423
424