Repository navigation
Expand file tree
/
Copy pathColors.pde
More file actions
170 lines (159 loc) · 4.93 KB
/
Copy pathColors.pde
File metadata and controls
170 lines (159 loc) · 4.93 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
// LED color definitions
static final int BLACK = 12;
static final int REDL = 13;
static final int RED = 15;
static final int AMBERL = 29;
static final int AMBER = 63;
static final int YELLOW = 62;
static final int GREEN = 60;
static final int GREENL = 28;
static final int REDF = 11;
static final int AMBERF = 59;
static final int YELLOWF = 58;
static final int GREENF = 56;
static final int BLUE = 90;
static final int BLUEL = 91;
static final int CYAN = 92;
static final int CYANL = 93;
static final int MAGENTA = 94;
static final int MAGENTAL = 95;
static final int WHITE = 96;
static final int WHITEL = 97;
int colors[] = new int[12];
static int SCROLLERCOLOR = RED;
// Button color definitions
static int BUTTONIDLECOLOR = AMBER;
static int HOLDONCOLOR = GREEN;
static int TOGGLEONCOLOR = GREEN;
static int TOGGLEOFFCOLOR = AMBER;
static int FADERIDLECOLOR = RED;
static int FADERACTIVECOLOR = GREEN;
static int SLIDERIDLECOLOR = GREENL;
static int SLIDERACTIVECOLOR = GREEN;
static int PAGEBUTTONIDLECOLOR = AMBER;
static int PAGEBUTTONACTIVECOLOR = GREEN;
static int INDICATOROFFCOLOR = RED;
static int INDICATORONCOLOR = GREEN;
static int PADOFFCOLOR = AMBER;
static int PADONCOLOR = YELLOW;
static int METERIDLECOLOR = AMBER;
static int METERACTIVECOLOR = GREEN;
static int PROGRESSIDLECOLOR = RED;
static int PROGRESSACTIVECOLOR = GREEN;
static int NOTEIDLECOLOR = YELLOW;
static int NOTEACTIVECOLOR = GREEN;
static int CCIDLECOLOR = YELLOW;
static int CCACTIVECOLOR = GREEN;
static int KBDIDLECOLOR = GREENL;
static int KBDACTIVECOLOR = GREEN;
static int PCIDLECOLOR = YELLOW;
static int PCACTIVECOLOR = GREEN;
int[] cdef = new int[26];
void storeDefaultColors() {
cdef[0] = BUTTONIDLECOLOR;
cdef[1] = HOLDONCOLOR;
cdef[2] = TOGGLEONCOLOR;
cdef[3] = TOGGLEOFFCOLOR;
cdef[4] = FADERIDLECOLOR;
cdef[5] = FADERACTIVECOLOR;
cdef[6] = SLIDERIDLECOLOR;
cdef[7] = SLIDERACTIVECOLOR;
cdef[8] = PAGEBUTTONIDLECOLOR;
cdef[9] = PAGEBUTTONACTIVECOLOR;
cdef[10] = INDICATOROFFCOLOR;
cdef[11] = INDICATORONCOLOR;
cdef[12] = PADOFFCOLOR;
cdef[13] = PADONCOLOR;
cdef[14] = METERIDLECOLOR;
cdef[15] = METERACTIVECOLOR;
cdef[16] = PROGRESSIDLECOLOR;
cdef[17] = PROGRESSACTIVECOLOR;
cdef[18] = NOTEIDLECOLOR;
cdef[19] = NOTEACTIVECOLOR;
cdef[20] = CCIDLECOLOR;
cdef[21] = CCACTIVECOLOR;
cdef[22] = KBDIDLECOLOR;
cdef[23] = KBDACTIVECOLOR;
cdef[24] = PCIDLECOLOR;
cdef[25] = PCACTIVECOLOR;
}
void defaultColors() {
BUTTONIDLECOLOR = cdef[0];
HOLDONCOLOR = cdef[1];
TOGGLEONCOLOR = cdef[2];
TOGGLEOFFCOLOR = cdef[3];
FADERIDLECOLOR = cdef[4];
FADERACTIVECOLOR = cdef[5];
SLIDERIDLECOLOR = cdef[6];
SLIDERACTIVECOLOR = cdef[7];
PAGEBUTTONIDLECOLOR = cdef[8];
PAGEBUTTONACTIVECOLOR = cdef[9];
INDICATOROFFCOLOR = cdef[10];
INDICATORONCOLOR = cdef[11];
PADOFFCOLOR = cdef[12];
PADONCOLOR = cdef[13];
METERIDLECOLOR = cdef[14];
METERACTIVECOLOR = cdef[15];
PROGRESSIDLECOLOR = cdef[16];
PROGRESSACTIVECOLOR = cdef[17];
NOTEIDLECOLOR = cdef[18];
NOTEACTIVECOLOR = cdef[19];
CCIDLECOLOR = cdef[20];
CCACTIVECOLOR = cdef[21];
KBDIDLECOLOR = cdef[22];
KBDACTIVECOLOR = cdef[23];
PCIDLECOLOR = cdef[24];
PCACTIVECOLOR = cdef[25];
}
int parseColor(String input) {
int scolor = BLACK;
if (input.equals("black")) { scolor = BLACK; }
if (input.equals("redlow")) { scolor = REDL; }
if (input.equals("red")) { scolor = RED; }
if (input.equals("amberlow")) { scolor = AMBERL; }
if (input.equals("amber")) { scolor = AMBER; }
if (input.equals("yellow")) { scolor = YELLOW; }
if (input.equals("greenlow")) { scolor = GREENL; }
if (input.equals("green")) { scolor = GREEN; }
if (input.equals("blue")) { scolor = BLUE; }
if (input.equals("bluelow")) { scolor = BLUEL ; }
if (input.equals("cyan")) { scolor = CYAN; }
if (input.equals("cyanlow")) { scolor = CYANL; }
if (input.equals("magenta")) { scolor = MAGENTA; }
if (input.equals("magentalow")) { scolor = MAGENTAL; }
if (input.equals("white")) { scolor = WHITE; }
if (input.equals("whitelow")) { scolor = WHITEL ; }
if (input.equals("redflash")) { scolor = REDF; }
if (input.equals("amberflash")) { scolor = AMBERF; }
if (input.equals("yellowflash")) { scolor = YELLOWF; }
if (input.equals("greenflash")) { scolor = GREENF; }
return scolor;
}
void setOffColors(int scolor) {
BUTTONIDLECOLOR = scolor;
TOGGLEOFFCOLOR = scolor;
FADERIDLECOLOR = scolor;
SLIDERIDLECOLOR = scolor;
INDICATOROFFCOLOR = scolor;
PADOFFCOLOR = scolor;
METERIDLECOLOR = scolor;
PROGRESSIDLECOLOR = scolor;
NOTEIDLECOLOR = scolor;
CCIDLECOLOR = scolor;
KBDIDLECOLOR = scolor;
PCIDLECOLOR = scolor;
}
void setOnColors(int scolor) {
HOLDONCOLOR = scolor;
TOGGLEONCOLOR = scolor;
FADERACTIVECOLOR = scolor;
SLIDERACTIVECOLOR = scolor;
INDICATORONCOLOR = scolor;
PADONCOLOR = scolor;
METERACTIVECOLOR = scolor;
PROGRESSACTIVECOLOR = scolor;
NOTEACTIVECOLOR = scolor;
CCACTIVECOLOR = scolor;
KBDACTIVECOLOR = scolor;
PCACTIVECOLOR = scolor;
}