168 {
169
170
171 FL_WARN(
"\n\n############## VU NOTES ################\n\n");
172
174
175 for (int i = 0; i < led_column_table_length; ++i) {
177
178
179
180 bool black_key = false;
181 switch (key.
mIdx % 12) {
182 case 1:
183 case 4:
184 case 6:
185 case 9:
186 case 11:
187 black_key = true;
188 break;
189 }
190
191 const int pixel_count = led_column_table[i];
193
194 const int black_pixel_count = pixel_count - draw_pixel_count;
196
197
198 const bool reverse_correct = black_key == (key.
mIdx % 2);
199
200 if (reverse_correct) {
201 for (int j = 0; j < draw_pixel_count; ++j) {
202 if (j < draw_pixel_count - 1) {
204 } else {
205
206 ColorHSV hsv(random(512) / 512.f, random(512) / 512.f, 1.0);
208 }
209 }
210
211 for (int j = 0; j < black_pixel_count; ++j) {
213 }
214 } else {
215 for (int j = 0; j < black_pixel_count; ++j) {
217 }
218
219 for (int j = draw_pixel_count - 1; j >= 0; --j) {
220 if (j < draw_pixel_count - 1) {
222 } else {
223
224 ColorHSV hsv(random(512) / 512.f, random(512) / 512.f, 1.0);
226 }
227 }
228 }
229 }
231}
LedRopeTCL led_rope(kNumKeys)
void RawDrawPixel(const Color3i &c)
Color3i * GetIterator(int i)
constexpr enable_if< is_fixed_point< T >::value, T >::type ceil(T x) FL_NOEXCEPT
constexpr enable_if< is_fixed_point< T >::value, T >::type sqrt(T x) FL_NOEXCEPT