FastLED 3.9.15
Loading...
Searching...
No Matches

◆ Gradient() [2/5]

fl::Gradient::Gradient ( const GradientInlined & other)

Definition at line 133 of file gradient.cpp.

133 {
134 // Visitor is cumbersome but guarantees all paths are handled.
135 struct Copy {
136 Copy(Gradient &owner) : mOwner(owner) {}
137 void accept(const CRGBPalette16 &palette) { mOwner.set(&palette); }
138 void accept(const CRGBPalette32 &palette) { mOwner.set(&palette); }
139 void accept(const CRGBPalette256 &palette) { mOwner.set(&palette); }
140 void accept(const GradientFunction &func) { mOwner.set(func); }
141 Gradient &mOwner;
142 };
143 Copy copy_to_self(*this);
144 other.variant().visit(copy_to_self);
145}
UINumberField palette("Palette", 0, 0, 2)

References Gradient(), palette(), fl::GradientInlined::variant(), and fl::Variant< Types >::visit().

+ Here is the call graph for this function: