I noticed that effects Noise 2 and Noise 3 (at minimum) are quite “pixelated” at very slow speeds (they shift by whole pixels), whereas others (Pride 2015) stay silky smooth (it shifts by fractions of a pixel, or something like that). Is this an improvement everyone wants (and is worth breaking backwards compatibility for?). I will play around with it regardless, but it’s extra motivating if others would appreciate it too.
I would love effects that are silky smooth.
IMHO, the only reason to keep effects pixelated is when the code is used as an example to explain how to develop effects.
One is all I need! (it helps for motivation too )
In this case it’s not even explicit, it’s just poor knowledge of C truncation and a compiler that apparently doesn’t even optimize for it, even with O3 enabled…
I’ll start with one for now and include it here as well.
In the end, I’m finding that this is really difficult for some reason. Perhaps others can help me.
A simple optimization is turning the below:
uint8_t noise = inoise16(real_x, real_y, real_z) >> 8; // get the noise data and scale it down
uint8_t index = sin8(noise * 3); // map LED color based on noise data
into a function that doesn’t truncate the last 3 bits. Like this:
uint8_t noise = inoise16(real_x, real_y, real_z) / (256 / 3); // get the noise data and scale it down
uint8_t index = sin8(noise); // map LED color based on noise data
However, this results in weird dark splotches showing up. I can’t intuitively figure out why this happens. While I probably will come back to this someday out of frustration, I’ve found the other noise patterns to fit my needs too.