- Parameters
-
| now | The current time in milliseconds. Fx writers are encouraged to use this instead of millis() directly as this will more deterministic behavior. |
Implements fl::Fx.
Definition at line 57 of file blend.cpp.hpp.
57 {
60
61
62 bool first = true;
65 tmp_ctx.leds =
mFrame->rgb();
66 auto &fx = it->fx;
67 fx->draw(tmp_ctx);
70 first = false;
71
72 u8 blur_amount = it->blur_amount;
73 if (blur_amount > 0) {
74 const XYMap &
xyMap = fx->getXYMap();
75 u8 blur_passes =
fl::max(1, it->blur_passes);
76 for (
u8 i = 0; i < blur_passes; ++i) {
77
80 }
81 }
83 }
84
86
92 for (
u8 i = 0; i < blur_passes; ++i) {
93
95 }
96 }
97
98
99
100
103}
fl::shared_ptr< Frame > mFrameTransform
fl::shared_ptr< Frame > mFrame
u16 xyMap(u16 x, u16 y) const FL_NO_EXCEPT
::fl::DrawContext DrawContext
static XYMap constructRectangularGrid(u16 width, u16 height, u16 offset=0) FL_NO_EXCEPT
constexpr common_type_t< T, U > max(T a, U b) FL_NO_EXCEPT
void blur2d(fl::span< CRGB > leds, u8 width, u8 height, fract8 blur_amount, const XYMap &xymap) FL_NO_EXCEPT
@ DRAW_MODE_BLEND_BY_MAX_BRIGHTNESS
References fl::blur2d(), fl::XYMap::constructRectangularGrid(), fl::DRAW_MODE_BLEND_BY_MAX_BRIGHTNESS, fl::DRAW_MODE_OVERWRITE, fl::FL_NO_EXCEPT, fl::height, fl::DrawContext::leds, fl::max(), mFrame, mFrameTransform, mGlobalBlurAmount, mGlobalBlurPasses, mLayers, fl::Fx2d::mXyMap, fl::width, and fl::Fx2d::xyMap().