FastLED 3.10.8
Loading...
Searching...
No Matches

◆ add() [2/2]

void fl::Blend2d::add ( Fx2dPtr layer,
const Params & p = Params() )

Definition at line 39 of file blend.cpp.hpp.

39 {
40 if (!layer->getXYMap().isRectangularGrid()) {
41 if (!getXYMap().isRectangularGrid()) {
42 FL_WARN("Blend2d has a xymap, but so does the Sub layer " << layer->fxName() << ", the sub layer will have it's map replaced with a rectangular map, to avoid double transformation.");
43 layer->setXYMap(XYMap::constructRectangularGrid(layer->getWidth(), layer->getHeight()));
44 }
45 }
46 u8 blurAmount = p.blur_amount;
47 u8 blurPasses = p.blur_passes;
48 Entry entry(layer, blurAmount, blurPasses);
49 mLayers.push_back(entry);
50}
vector< Entry > mLayers
Definition blend.h:57
XYMap & getXYMap() FL_NO_EXCEPT
Definition fx2d.h:27
static XYMap constructRectangularGrid(u16 width, u16 height, u16 offset=0) FL_NO_EXCEPT
Definition xymap.cpp.hpp:36
#define FL_WARN(...)
Definition log.h:437
unsigned char u8
Definition stdint.h:131
Definition blend.h:49

References fl::XYMap::constructRectangularGrid(), fl::FL_NO_EXCEPT, FL_WARN, fl::Fx2d::getXYMap(), and mLayers.

+ Here is the call graph for this function: