LightCluster.h 693 B

12345678910111213141516171819202122232425262728293031323334353637
  1. //
  2. // Created by emilr on 2022-04-13.
  3. //
  4. #include "stdint.h"
  5. #include "Animations.h"
  6. #include "main.h"
  7. #ifndef UNTITLED_LIGHTCLUSTER_H
  8. #define UNTITLED_LIGHTCLUSTER_H
  9. class LightCluster {
  10. private:
  11. unsigned long lastRun;
  12. void runSetup();
  13. bool shouldRun();
  14. public:
  15. int numLights;
  16. int animationNumber;
  17. uint32_t maxBrightness;
  18. bool useMaxBrightness;
  19. uint8_t brightness = 255;
  20. bool runAnimation();
  21. void changeAnimation(int newAnimationNumber);
  22. LightCluster(light *incomingLights, int size, int animation, Animations *animationObject);
  23. ~LightCluster();
  24. light *lights;
  25. Animations *animationObject;
  26. };
  27. #endif //UNTITLED_LIGHTCLUSTER_H