]> git.immae.eu Git - perso/Immae/Projets/Python/MusicSampler.git/blob - config.yml
Fix crash when click on unconfigured key
[perso/Immae/Projets/Python/MusicSampler.git] / config.yml
1 #################################
2 ##### General configuration #####
3 ## Keep in mind that in-line option override these
4
5 #option listed here are the default options.
6 config:
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
15 # built-in mixing, try this if your system can't mix the musics by itself
16 builtin_mixing: false
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
29 ###################
30 ##### Aliases #####
31
32 aliases:
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:
56 color: [190, 110, 236]
57 pink:
58 color: [255, 50, 255]
59
60 ####################################################
61 ##### Music properties: name and general gain ######
62
63 music_properties:
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
70 gain: 1.2
71
72 ###############################################################################
73 ##### Key properties: how do the key look like, and some other properties #####
74
75 key_properties:
76 'common':
77 repeat_delay: 1
78 'a':
79 description:
80 -
81 - Music 1
82 include: light_blue
83 'z':
84 description:
85 -
86 - Music 2
87 include: light_blue
88 'e':
89 description:
90 -
91 - Noise
92 include: light_blue
93 't':
94 description:
95 -
96 - Crossfade
97 - music 2
98 include: green
99 repeat_delay: 5
100 'y':
101 description:
102 -
103 - Stop wait
104 - music 2
105 include: green
106 'u':
107 description:
108 -
109 - Noise
110 - + Music 2
111 include: green
112
113 'g':
114 description:
115 -
116 - Music 1
117 - Seek 30/60
118 include: purple
119
120 'i':
121 description:
122 -
123 - Noise
124 - +low vol
125 include: green
126
127 'h':
128 description:
129 -
130 - Noise
131 - 3 times
132 include: purple
133 repeat_delay: 2
134
135 'm':
136 description:
137 -
138 - Musics
139 - 1 & 2
140 include: purple
141
142 'n':
143 description:
144 -
145 - Low vol
146 - Up vol
147 include: green
148
149 'home':
150 description:
151 -
152 - vlc
153 include: orange
154
155
156 ## Some general useful keys
157
158 'ESC':
159 description:
160 - "!"
161 - STOP!
162 include: red
163
164 'F5':
165 description:
166 - "||"
167 - PAUSE
168 include: light_green
169
170 'F6':
171 description:
172 - ">"
173 - UNPAUSE
174 include: light_green
175
176 'F1':
177 description:
178 -
179 - Stop
180 - fade
181 include: orange
182
183 'F2':
184 description:
185 -
186 - Stop
187 - actions
188 include: orange
189
190 'F4':
191 description:
192 -
193 - Skip
194 - wait
195 include: pink
196
197 'F12':
198 description:
199 -
200 - vol+
201 include: yellow
202
203 'F11':
204 description:
205 -
206 - "vol-"
207 include: yellow
208
209 'right':
210 description:
211 -
212 - +10s
213 include: blue
214
215 'left':
216 description:
217 -
218 - -10s
219 include: blue
220
221 #################################################################
222 ##### Keys: what do the key actually do when you press them #####
223
224 keys:
225 # Play the songs
226 'a':
227 - play:
228 include: music1
229 'z':
230 - play:
231 include: music2
232 'e':
233 - play:
234 include: noise
235
236 # Crossfade from any music to music 2
237 't':
238 - stop:
239 fade_out: 5
240 - play:
241 include: music2
242 fade_in: 5
243
244 # Fade out, then wait and start music 2
245 'y':
246 - stop:
247 fade_out: 3
248 wait: true
249 set_wait_id: y1
250 - wait:
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':
258 - play:
259 include: noise
260 - wait:
261 duration: 0.2
262 - stop:
263 include: music1
264 - wait:
265 duration: 3
266 set_wait_id: u
267 - play:
268 include: music2
269
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)
284 'm':
285 - stop:
286 fade_out: 2
287 wait: true
288 - play:
289 include: music1
290 - wait:
291 include: music1
292 set_wait_id: m
293 - play:
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
304 - play:
305 include: noise
306 - wait:
307 include: noise
308 duration: 1
309 set_wait_id: i
310 - volume:
311 include: music1
312 value: 100
313 fade: 1
314 - volume:
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' :
321 - volume:
322 include: music1
323 value: 10
324 fade: 5
325 - volume:
326 include: music2
327 value: 10
328 fade: 5
329 - wait:
330 duration: 5
331 set_wait_id: n
332 - volume:
333 include: music1
334 value: 100
335 fade: 5
336 - volume:
337 include: music2
338 value: 100
339 fade: 5
340
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
353
354
355 ##### Useful keys (good to have them all the time)
356
357 # Emergency stop!
358 'ESC':
359 - stop_all_actions:
360 other_only: true
361 - stop:
362
363
364
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':
374 - stop:
375 fade_out: 1
376
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