da0645beeff1e26f579561a9880de26602fb9fae
[minwii.git] / src / app / config.py
1 # -*- coding: utf-8 -*-
2 """
3 constantes de configuration
4
5 $Id$
6 $URL$
7 """
8
9 import pygame
10 import os.path
11 pygame.font.init()
12
13
14 # playingscreen
15 FRAMERATE = 50
16 BORDER = 0 # 5px
17 FIRST_HUE = 0.6
18 OFF_LUMINANCE = 0.2
19 OFF_SATURATION = 1
20 ON_TOP_LUMINANCE = 0.6
21 ON_BOTTOM_LUMINANCE = 0.9
22 ON_SATURATION = 1
23 ON_COLUMN_OVERSIZING = 2
24 ON_COLUMN_ALPHA = 1
25 FONT = pygame.font.Font(None, 80)
26 FONT_COLOR = (0,0,0)
27 DEFAULT_MIDI_VELOCITY = 96
28
29 SONG_FILE_PATH = '../../chansons'
30
31 INSTRUMENTS = (
32 {'name' : 'accordeon',
33 'bank' : 0,
34 'preset' : 23
35 },
36 {'name' : 'celesta',
37 'bank' : 0,
38 'preset' : 8
39 },
40 {'name' : 'flute',
41 'bank' : 0,
42 'preset' : 73
43 },
44 {'name' : 'guitare',
45 'bank' : 0,
46 'preset' : 24,
47 'octave' : -1
48 },
49 {'name' : 'orgue',
50 'bank' : 0,
51 'preset' : 19
52 },
53 {'name' : 'piano',
54 'bank' : 0,
55 'preset' : 0
56 },
57 {'name' : 'tuba',
58 'bank' : 0,
59 'preset' : 58,
60 'octave' : -2
61 },
62 {'name' : 'violon',
63 'bank' : 0,
64 'preset' : 40
65 },
66 {'name' : 'violoncelle',
67 'bank' : 0,
68 'preset' : 42,
69 'octave' : -2
70 },
71 )
72
73 # cuisine : ne pas modifier
74 _here = os.path.abspath(__file__).split(os.path.sep)[:-1]
75 SONG_FILE_PATH = SONG_FILE_PATH.split('/')
76 SONG_FILE_PATH = _here + SONG_FILE_PATH
77 SONG_FILE_PATH = os.path.abspath(os.path.sep.join(SONG_FILE_PATH))
78
79