PicoWaveTracker/LedMatrix.h
2026-03-06 21:35:21 +01:00

29 lines
713 B
C++

#ifndef LED_MATRIX_H
#define LED_MATRIX_H
#include <Adafruit_NeoPixel.h>
#include "TrackerTypes.h"
#include "config.h"
class LedMatrix {
public:
LedMatrix();
void begin();
void update(const Step sequence[][NUM_STEPS], int playbackStep, bool isPlaying,
UIState currentState, bool songModeEnabled,
int songRepeatsRemaining, bool sequenceChangeScheduled, PlayMode playMode,
int selectedTrack, const int* numSteps, const bool* trackMute);
void setBrightness(uint8_t b);
void clear();
void show();
private:
Adafruit_NeoPixel pixels;
uint32_t getNoteColor(int note, bool dim);
int getPixelIndex(int x, int y);
};
#endif