Skip to content

Commit 41afdf4

Browse files
authored
Update README.md
1 parent 9970594 commit 41afdf4

File tree

1 file changed

+5
-8
lines changed

1 file changed

+5
-8
lines changed

usermods/user_fx/README.md

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -42,19 +42,16 @@ Below are some helpful variables and functions to know as you start your journey
4242
| `strip.now` | 32-bit | Current timestamp in milliseconds. (Equivalent to `millis()`, but use `strip.now()` instead.) |
4343
| `SEGLEN / SEG_W / SEG_H` | 16-bit | These variables are macros that help define the length and width of your LED strip/matrix segment. |
4444
| `hw_random8()` | 8-bit | Generates a random integer. All random number functions can be found [here](https://github.com/wled/WLED/blob/7b0075d3754fa883fc1bbc9fbbe82aa23a9b97b8/wled00/fcn_declare.h#L535). |
45-
4645
| `SEGCOLOR(x)` | --- | Gets user-selected colors from UI, where x is an integer 1, 2, or 3 for primary, secondary, and tertiary colors, respectively. (and how it relates to meta string??) |
4746
| `SEGMENT.setPixelColor / setPixelColorXY` | --- | Fuction that paints a single pixel to your specified color. `setPixelColor` assumes 1D array and requires one positional argument, while `setPixelColorXY` takes two positional arguments (x and y), and then the RBG color value. |
4847
| `SEGPALETTE` | --- | This is the currently selected palette for the currently processing segment. |
49-
| `SEGMENT.color_from_palette()` | ??? | Gets a single color from the currently selected palette for a segment. (This function which should be favoured over `ColorFromPalette()`.) <br />Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
50-
51-
| `fade` | ??? | There are several different fade functions that make it easy to accomplish different fading tasks; these are all detailed in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). An example would be `fadeToBlackBy()` which can be used to fade all pixels to black. |
52-
| `move()` | ??? | Moves/shifts pixels in the desired direction. Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
53-
| `blur / blur2d` | ??? | Blurs all pixels for the desired segment. Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
48+
| `SEGMENT.color_from_palette()` | 32-bit | Gets a single color from the currently selected palette for a segment. (This function which should be favoured over `ColorFromPalette()`.) <br />Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
49+
| `fade` | --- | There are several different fade functions that make it easy to accomplish different fading tasks; these are all detailed in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). An example would be `fadeToBlackBy()` which can be used to fade all pixels to black. |
50+
| `move()` | --- | Moves/shifts pixels in the desired direction. Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
51+
| `blur / blur2d` | --- | Blurs all pixels for the desired segment. Defined in [FX_fcn.cpp](https://github.com/wled/WLED/blob/main/wled00/FX_fcn.cpp). |
5452

53+
Importing `wled.h` brings all of the variables, files, and functions listed above (and more) into your custom effect for your use, as you will see in the examples below.
5554

56-
| FX.h
57-
| `FX_fcn / FX_2Dfcn` | --- | These files contain |
5855

5956

6057
## Understanding 2D WLED Effects

0 commit comments

Comments
 (0)