G.U.L.L.S. rebuilt to use PlatformIO
This commit is contained in:
41
include/FluidColorMatrix.h
Normal file
41
include/FluidColorMatrix.h
Normal file
@@ -0,0 +1,41 @@
|
||||
#ifndef FLUIDCOLORMATRIX_H
|
||||
#define FLUIDCOLORMATRIX_H
|
||||
|
||||
#include "MatrixAnimation.h"
|
||||
|
||||
enum FluidColorType {
|
||||
PIXEL_BY_PIXEL_FLUIDCOLOR,
|
||||
HORIZONTAL_FLUIDCOLOR,
|
||||
VERTICAL_FLUIDCOLOR
|
||||
};
|
||||
|
||||
enum FluidColorResolution {
|
||||
FULL_FLUIDCOLOR,
|
||||
HALF_FLUIDCOLOR,
|
||||
QUATER_FLUIDCOLOR,
|
||||
EIGHTH_FLUIDCOLOR
|
||||
};
|
||||
|
||||
class FluidColorMatrix : public MatrixAnimation {
|
||||
public:
|
||||
FluidColorMatrix(LEDHAL2D* _matrix, char* _refName, long _updateTime,
|
||||
FluidColorType _type, FluidColorResolution _resolution) : MatrixAnimation(_matrix,
|
||||
_refName, _updateTime), type(_type), resolution(_resolution), colorShifter(0) {}
|
||||
virtual ~FluidColorMatrix() { delete[] colors; }
|
||||
|
||||
void initialize();
|
||||
void execute();
|
||||
private:
|
||||
uint16_t
|
||||
colorShifter;
|
||||
CRGB*
|
||||
colors;
|
||||
uint8_t
|
||||
numColors;
|
||||
FluidColorType
|
||||
type;
|
||||
FluidColorResolution
|
||||
resolution;
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user