setUpMatrix bug fix
This commit is contained in:
@@ -133,6 +133,7 @@ void WS2812FX::setUpMatrix(bool reset) {
|
||||
if (customMappingSizeLedmap > 0) { //WLEDMM: @Troy#2642 : include ledmap = 0 as default ledmap
|
||||
if (index < customMappingSizeLedmap && customMappingTable[index] < customMappingSize)
|
||||
customMappingTableCombi[customMappingTable[index]] = pix; //WLEDMM: allow for 2 transitions if reset = false (ledmap and logical to physical)
|
||||
pix++;
|
||||
}
|
||||
else {
|
||||
if (!gapTable || (gapTable && gapTable[index] > 0)) customMappingTable[index] = pix; // a useful pixel (otherwise -1 is retained)
|
||||
@@ -142,6 +143,13 @@ void WS2812FX::setUpMatrix(bool reset) {
|
||||
}
|
||||
}
|
||||
|
||||
if (customMappingSizeLedmap > 0) { //WLEDMM: @Troy#2642 : include ledmap = 0 as default ledmap
|
||||
for (size_t i = 0; i < customMappingSize; i++) {
|
||||
customMappingTable[i] = customMappingTableCombi[i];
|
||||
}
|
||||
delete[] customMappingTableCombi;
|
||||
}
|
||||
|
||||
// delete gap array as we no longer need it
|
||||
if (gapTable) delete[] gapTable;
|
||||
|
||||
@@ -160,7 +168,7 @@ void WS2812FX::setUpMatrix(bool reset) {
|
||||
panel.clear();
|
||||
Segment::maxWidth = _length;
|
||||
Segment::maxHeight = 1;
|
||||
resetSegments();
|
||||
//WLEDMM: no resetSegments here, only do it in set.cpp/handleSettingsSet
|
||||
}
|
||||
}
|
||||
#else
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
*/
|
||||
|
||||
// version code in format yymmddb (b = daily build)
|
||||
#define VERSION 2302230
|
||||
#define VERSION 2302231
|
||||
|
||||
//uncomment this if you have a "my_config.h" file you'd like to use
|
||||
//#define WLED_USE_MY_CONFIG
|
||||
|
||||
Reference in New Issue
Block a user