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

◆ getLedsBufferBytesForPin()

span< u8 > fl::RectangularDrawBuffer::getLedsBufferBytesForPin ( u8 pin,
bool clear_first = true )

Definition at line 18 of file rectangular_draw_buffer.cpp.

18 {
19 auto it = mPinToLedSegment.find(pin);
20 if (it == mPinToLedSegment.end()) {
21 FASTLED_ASSERT(false, "Pin not found in RectangularDrawBuffer");
22 return fl::span<u8>();
23 }
24 fl::span<u8> slice = it->second;
25 if (clear_first) {
26 memset(slice.data(), 0, slice.size() * sizeof(slice[0]));
27 }
28 return slice;
29}
fl::FixedMap< u8, fl::span< u8 >, 50 > mPinToLedSegment
const T * data() const
Definition slice.h:138
fl::size size() const
Definition slice.h:142
Slice< T > span
Definition span.h:8

References fl::Slice< T >::data(), mPinToLedSegment, and fl::Slice< T >::size().

+ Here is the call graph for this function: