#ifndef LEDMATRIX_H
#define LEDMATRIX_H

#include <FastLED.h>
#include <stdint.h>

class LEDMatrix {
public:
  LEDMatrix(uint8_t width, uint8_t height, uint16_t numLeds, uint16_t lastVisibleLed, CRGB* leds);
  uint16_t XY(uint8_t x, uint8_t y);
  void drawPixel(uint8_t x, uint8_t y, CRGB color);
  void drawChar(char c, int x, int y, CRGB color);
  void drawText(const char* text, int x, int y, CRGB color);

private:
  const uint8_t kMatrixWidth;
  const uint8_t kMatrixHeight;
  const uint16_t NUM_LEDS;
  const uint16_t LAST_VISIBLE_LED;
  const int* XYTable;
  CRGB* leds; // Add this line
};

#endif // LEDMATRIX_H