25 if (tiles.
size() == 0) {
34 for (
const auto &tile : tiles) {
44 for (
int x = 0;
x < 2; ++
x) {
45 for (
int y = 0;
y < 2; ++
y) {
46 uint8_t value = tile.
at(
x,
y);
50 int xx = origin.
x +
x;
51 int yy = origin.
y +
y;
52 if (optional_bounds && !optional_bounds->
contains(xx, yy)) {
XYMap xymap(WIDTH, HEIGHT, SERPENTINE)
vec2< int > origin() const
uint8_t & at(int x, int y)
void write(const vec2< int > &pt, uint8_t value)
fl::rect< int > mAbsoluteBounds
void rasterize_internal(const Tile2x2_u8 &tile, const rect< int > *optional_bounds=nullptr)
void draw(const CRGB &color, const XYMap &xymap, CRGB *out)
void drawGradient(const Gradient &gradient, const XYMap &xymap, CRGB *out)
void rasterize(const vec2< int > &pt, uint8_t value)
Implements a simple red square effect for 2D LED grids.
Representation of an RGB pixel (Red, Green, Blue)
bool contains(const vec2< T > &p) const