FastLED
3.9.15
Loading...
Searching...
No Matches
draw_context.h
Go to the documentation of this file.
1
#pragma once
2
3
#include "
crgb.h
"
4
#include "
fl/namespace.h
"
5
#include <
stdint.h
>
6
7
namespace
fl
{
8
9
// Abstract base class for effects on a strip/grid of LEDs.
10
11
struct
_DrawContext
{
12
uint32_t
now
;
13
CRGB
*
leds
;
14
uint16_t
frame_time
= 0;
15
float
speed
= 1.0f;
16
_DrawContext
(uint32_t
now
,
CRGB
*
leds
, uint16_t
frame_time
= 0,
17
float
speed
= 1.0f)
18
:
now
(
now
),
leds
(
leds
),
frame_time
(
frame_time
),
speed
(
speed
) {}
19
};
20
21
}
// namespace fl
crgb.h
Defines the red, green, and blue (RGB) pixel struct.
namespace.h
Implements the FastLED namespace macros.
fl
Implements a simple red square effect for 2D LED grids.
Definition
crgb.h:16
stdint.h
CRGB
Representation of an RGB pixel (Red, Green, Blue)
Definition
crgb.h:55
fl::_DrawContext::now
uint32_t now
Definition
draw_context.h:12
fl::_DrawContext::_DrawContext
_DrawContext(uint32_t now, CRGB *leds, uint16_t frame_time=0, float speed=1.0f)
Definition
draw_context.h:16
fl::_DrawContext::frame_time
uint16_t frame_time
Definition
draw_context.h:14
fl::_DrawContext::leds
CRGB * leds
Definition
draw_context.h:13
fl::_DrawContext::speed
float speed
Definition
draw_context.h:15
fx
detail
draw_context.h
Generated on Thu May 29 2025 04:44:57 for FastLED by
1.13.2