Add CustomEffects as usermod: step 3: effects start working

This commit is contained in:
Ewowi
2022-08-30 23:12:04 +02:00
parent ddeb5732c6
commit 8626855953
6 changed files with 1975 additions and 2015 deletions

View File

@@ -634,8 +634,6 @@ typedef struct Segment {
} segment;
//static int segSize = sizeof(Segment);
#define floatNull -32768 //WLEDSR Custom Effects
// main "strip" class
class WS2812FX { // 96 bytes
typedef uint16_t (*mode_ptr)(void); // pointer to mode function
@@ -900,12 +898,6 @@ class WS2812FX { // 96 bytes
void
estimateCurrentAndLimitBri(void);
public:
//WLEDSR Custom Effects
float arti_external_function(uint8_t function, float par1 = floatNull, float par2 = floatNull, float par3 = floatNull, float par4 = floatNull, float par5 = floatNull);
float arti_get_external_variable(uint8_t variable, float par1 = floatNull, float par2 = floatNull, float par3 = floatNull);
void arti_set_external_variable(float value, uint8_t variable, float par1 = floatNull, float par2 = floatNull, float par3 = floatNull);
};
extern const char JSON_mode_names[];

View File

@@ -684,11 +684,7 @@ function populateSegments(s)
let li = lastinfo;
segCount = 0; lowestUnused = 0; lSeg = 0;
console.log(s);
for (var inst of (s.seg||[])) {
console.log(inst);
segCount++;
let i = parseInt(inst.id);

File diff suppressed because it is too large Load Diff