FastLED 3.10.6
Loading...
Searching...
No Matches

◆ PixelIteratorAny() [3/4]

fl::PixelIteratorAny::PixelIteratorAny ( const PixelIteratorAny & other)
inline

Copy: the iterator must be re-aimed, not copied.

This class is self-referential – mPixelIterator is a type-erased PixelIterator holding a void* into mController, a member of the same object. The compiler-generated copy carried that pointer across unchanged, so the copy's iterator kept reading the source object's controller. Where the source was a temporary, as in ReorderingPixelIteratorAny's addressing branch, that was a read of dead stack on every addressed frame (#4201).

Definition at line 66 of file pixel_iterator_any.h.

67 : mController(other.mController), mOrder(other.mOrder),
68 mRgbw(other.mRgbw), mRgbww(other.mRgbww), mXyMap(other.mXyMap) {
70 }
PixelController< RGB > mController
void bindIterator()
Point mPixelIterator at this object's own controller.
fl::shared_ptr< const XYMap > mXyMap

References PixelIteratorAny(), bindIterator(), and fl::FL_NO_EXCEPT.

+ Here is the call graph for this function: