effect parameter tinkering
* freqmap: fade faster * Lissajous HD mode: color follows rotation
This commit is contained in:
@@ -4963,6 +4963,7 @@ uint16_t mode_2Dgameoflife(void) { // Written by Ewoud Wijma, inspired by https:
|
||||
bool repetition = false;
|
||||
for (int i=0; i<crcBufferLen && !repetition; i++) repetition = (crc == crcBuffer[i]); // (Ewowi)
|
||||
// same CRC would mean image did not change or was repeating itself
|
||||
// -> softhack007: not exacly. Different CRC means diferent image; same CRC means nothing (could be same or slightly different).
|
||||
if (!repetition) SEGENV.step = strip.now; //if no repetition avoid reset
|
||||
// remember CRCs across frames
|
||||
crcBuffer[SEGENV.aux0] = crc;
|
||||
@@ -5131,7 +5132,9 @@ uint16_t mode_2DLissajous(void) { // By: Andrew Tuline
|
||||
for (int i=0; i < maxLoops; i ++) {
|
||||
float xlocn = float(sin8(phase/2 + (i* SEGMENT.speed)/64)) / 255.0f; // WLEDMM align speed with original effect
|
||||
float ylocn = float(cos8(phase/2 + i*2)) / 255.0f;
|
||||
SEGMENT.setPixelColorXY(xlocn, ylocn, SEGMENT.color_from_palette(millis()/100+i, false, PALETTE_SOLID_WRAP, 0)); // draw pixel with anti-aliasing
|
||||
//SEGMENT.setPixelColorXY(xlocn, ylocn, SEGMENT.color_from_palette(millis()/100+i, false, PALETTE_SOLID_WRAP, 0)); // draw pixel with anti-aliasing
|
||||
unsigned palIndex = (256*ylocn) + phase/2 + (i* SEGMENT.speed)/64;
|
||||
SEGMENT.setPixelColorXY(xlocn, ylocn, SEGMENT.color_from_palette(palIndex, false, PALETTE_SOLID_WRAP, 0)); // draw pixel with anti-aliasing - color follows rotation
|
||||
}
|
||||
} else
|
||||
for (int i=0; i < 256; i ++) {
|
||||
@@ -6976,7 +6979,7 @@ uint16_t mode_freqmap(void) { // Map FFT_MajorPeak to SEGLEN.
|
||||
SEGMENT.setUpLeds();
|
||||
SEGMENT.fill(BLACK);
|
||||
}
|
||||
int fadeoutDelay = (256 - SEGMENT.speed) / 32;
|
||||
int fadeoutDelay = (256 - SEGMENT.speed) / 96; // WLEDMM
|
||||
if ((fadeoutDelay <= 1 ) || ((SEGENV.call % fadeoutDelay) == 0)) SEGMENT.fade_out(SEGMENT.speed);
|
||||
|
||||
int locn = (log10f((float)FFT_MajorPeak) - 1.78f) * (float)SEGLEN/(MAX_FREQ_LOG10 - 1.78f); // log10 frequency range is from 1.78 to 3.71. Let's scale to SEGLEN.
|
||||
@@ -7000,7 +7003,7 @@ uint16_t mode_freqmap(void) { // Map FFT_MajorPeak to SEGLEN.
|
||||
|
||||
return FRAMETIME_FIXED;
|
||||
} // mode_freqmap()
|
||||
static const char _data_FX_MODE_FREQMAP[] PROGMEM = "Freqmap@Fade rate,Starting color;!,!;!;1f;m12=0,si=0"; // Pixels, Beatsin
|
||||
static const char _data_FX_MODE_FREQMAP[] PROGMEM = "Freqmap@Fade rate,Starting color;!,!;!;1f;sx=192,m12=0,si=0"; // Pixels, Beatsin
|
||||
|
||||
|
||||
///////////////////////
|
||||
|
||||
Reference in New Issue
Block a user