16 for (u16 w = 0; w <
width; w++) {
17 for (u16 h = 0; h <
height; h++) {
19 vec2f p = {
static_cast<float>(w),
static_cast<float>(h)};
44 const u16 *lookUpTable,
53 if (lookUpTable !=
nullptr) {
71 u16
length = xmap.getLength();
78 u16* data = lut->getDataMutable();
81 for (u16 i = 0; i <
length; i++) {
82 data[i] = xmap.mapToIndex(i);
85 out.mLookUpTable = lut;
void setSourceXYMap(const fl::shared_ptr< XYMap > &xymap) FL_NO_EXCEPT
Set the source XYMap (used for pixel transformation during encoding)
void set(u16 index, const vec2f &p) FL_NO_EXCEPT
fl::ScreenMap toScreenMap() const FL_NO_EXCEPT
u16 getHeight() const FL_NO_EXCEPT
void mapPixels(const CRGB *input, CRGB *output) const FL_NO_EXCEPT
void setRectangularGrid() FL_NO_EXCEPT
static XYMap constructSerpentine(u16 width, u16 height, u16 offset=0) FL_NO_EXCEPT
static XYMap constructWithUserFunction(u16 width, u16 height, XYFunction xyFunction, u16 offset=0) FL_NO_EXCEPT
u16 mapToIndex(const u16 &x, const u16 &y) const FL_NO_EXCEPT
u16 getTotal() const FL_NO_EXCEPT
u16 getWidth() const FL_NO_EXCEPT
XyMapType getType() const FL_NO_EXCEPT
static XYMap constructRectangularGrid(u16 width, u16 height, u16 offset=0) FL_NO_EXCEPT
void convertToLookUpTable() FL_NO_EXCEPT
static XYMap constructWithLookUpTable(u16 width, u16 height, const u16 *lookUpTable, u16 offset=0) FL_NO_EXCEPT
fl::LUT16Ptr mLookUpTable
static XYMap fromXMap(const XMap &xmap) FL_NO_EXCEPT
Create an XYMap from an XMap (treats 1D as 2D with height=1)
XYMap(u16 width, u16 height, bool is_serpentine=true, u16 offset=0) FL_NO_EXCEPT
fl::UISlider length("Length", 1.0f, 0.0f, 1.0f, 0.01f)
fl::UISlider offset("Offset", 0.0f, 0.0f, 1.0f, 0.01f)
shared_ptr< T > make_shared(Args &&... args) FL_NO_EXCEPT
u8 u8 fract8 blur_amount FL_NO_EXCEPT
u16(* XYFunction)(u16 x, u16 y, u16 width, u16 height)
FASTLED_FORCE_INLINE void * memcpy(void *dest, const void *src, size_t n) FL_NO_EXCEPT
FASTLED_FORCE_INLINE u16 xy_line_by_line(u16 x, u16 y, u16 width, u16 height) FL_NO_EXCEPT
FASTLED_FORCE_INLINE u16 xy_serpentine(u16 x, u16 y, u16 width, u16 height) FL_NO_EXCEPT
Base definition for an LED controller.
Representation of an 8-bit RGB pixel (Red, Green, Blue)