48 for (
int x = 0;
x < 2; ++
x) {
49 for (
int y = 0;
y < 2; ++
y) {
74 mData[0][0] = data[0][0];
75 mData[0][1] = data[0][1];
76 mData[1][0] = data[1][0];
77 mData[1][1] = data[1][1];
113 for (
int x = 0;
x < 2; ++
x) {
114 for (
int y = 0;
y < 2; ++
y) {
144 for (u16
x = 0;
x < 2; ++
x) {
145 for (u16
y = 0;
y < 2; ++
y) {
146 const auto& data_a = a.
at(
x,
y);
147 const auto& data_b = b.
at(
x,
y);
154 u8 alpha_a = data_a.second;
155 u8 alpha_b = data_b.second;
158 float alpha_float = alpha_a +
t * (alpha_b - alpha_a);
159 u8 interpolated_alpha =
static_cast<u8>(alpha_float + 0.5f);
161 interpolated.
mData[
y][
x] = {
pos, interpolated_alpha};
165 result.push_back(interpolated);
fl::pair< vec2< u16 >, u8 > Entry
static vector_fixed< Tile2x2_u8_wrap, 2 > Interpolate(const Tile2x2_u8_wrap &a, const Tile2x2_u8_wrap &b, float t)
Tile2x2_u8_wrap() FL_NOEXCEPT
static Tile2x2_u8 MaxTile(const Tile2x2_u8 &a, const Tile2x2_u8 &b)
void draw(const CRGB &color, const XYMap &xymap, fl::span< CRGB > out) const
static void Rasterize(const span< const Tile2x2_u8 > &tiles, XYRasterU8Sparse *output)
vec2< u16 > origin() const
Tile2x2_u8() FL_NOEXCEPT=default
rect< u16 > bounds() const
bounds => [begin_x, end_x) (where end_x is exclusive)
void rasterize(const vec2< u16 > &pt, u8 value)
Defines the 8-bit red, green, and blue (RGB) pixel type in the fl namespace.
Centralized logging categories for FastLED hardware interfaces and subsystems.
static vec2< u16 > wrap_x(const vec2< u16 > &v, const u16 width)
static vec2< u16 > wrap(const vec2< u16 > &v, const vec2< u16 > &size)
FL_DISABLE_WARNING_PUSH U constexpr common_type_t< T, U > min(T a, U b) FL_NOEXCEPT
constexpr int type_rank< T >::value
constexpr common_type_t< T, U > max(T a, U b) FL_NOEXCEPT
expected< T, E > result
Alias for expected (Rust-style naming)
FixedVector< T, INLINED_SIZE > vector_fixed
Base definition for an LED controller.
Representation of an 8-bit RGB pixel (Red, Green, Blue)