Unified bit transposition functions for FastLED.
This file consolidates all bit transposition and bit-interleaving functions used throughout FastLED for various parallel LED output methods:
Core 8x1 Bit Transpose (from bitswap.h)
- Basic 8-byte by 8-bit rotation functions
- Based on Hacker's Delight algorithms
- Used by parallel output drivers on ARM, ESP8266, ESP32
SPI Multi-Lane Transposer
- Bit-interleaving for 2/4/8/16-way SPI parallel transmission
- Unified stateless functional design
- Used by APA102, SK9822, LPD8806, WS2801, P9813 controllers
Parallel Strip Transposer (RP2040/RP2350)
- Transpose N LED strips into bit-parallel format for PIO
- Optimized for 2/4/8 strip configurations
- Used by RP2040/RP2350 PIO-based parallel output
Definition in file transposition.h.
|
| FASTLED_FORCE_INLINE u32 | fl::calculate_transpose_buffer_size (u16 num_leds, u8 bytes_per_led) FL_NOEXCEPT |
| | Calculate output buffer size needed for transposed data.
|
| |
| template<int m, int n> |
| FASTLED_FORCE_INLINE void | fl::transpose8 (unsigned char *A, unsigned char *B) FL_NOEXCEPT |
| | Templated 8x8 bit transpose with custom stride.
|
| |
| FASTLED_FORCE_INLINE void | fl::transpose8x1 (unsigned char *A, unsigned char *B) FL_NOEXCEPT |
| | Simplified 8x1 bit transpose (inline version)
|
| |
| FASTLED_FORCE_INLINE void | fl::transpose8x1_MSB (unsigned char *A, unsigned char *B) FL_NOEXCEPT |
| | Simplified 8x1 bit transpose with MSB-first output.
|
| |
| void | fl::transpose8x1_noinline (unsigned char *A, unsigned char *B) FL_NOEXCEPT |
| | Simplified 8x1 bit transpose (non-inline version)
|
| |
| void | fl::transpose_16lane_inline (const u8 *const lanes[16], u8 *output, size_t num_bytes) FL_NOEXCEPT |
| | Low-level bit-interleaving primitive for 16 lanes (ISR-safe)
|
| |
| void | fl::transpose_2lane_inline (const u8 *lane0_byte, const u8 *lane1_byte, u8 *output, size_t num_bytes) FL_NOEXCEPT |
| | Low-level bit-interleaving primitive for 2 lanes (ISR-safe)
|
| |
| FASTLED_FORCE_INLINE void | fl::transpose_2strips (const u8 *const input[2], u8 *output, u16 num_leds, u8 bytes_per_led) FL_NOEXCEPT |
| | Transpose 2 LED strips into parallel bit format.
|
| |
| void | fl::transpose_4lane_inline (const u8 *const lanes[4], u8 *output, size_t num_bytes) FL_NOEXCEPT |
| | Low-level bit-interleaving primitive for 4 lanes (ISR-safe)
|
| |
| FASTLED_FORCE_INLINE void | fl::transpose_4strips (const u8 *const input[4], u8 *output, u16 num_leds, u8 bytes_per_led) FL_NOEXCEPT |
| | Transpose 4 LED strips into parallel bit format.
|
| |
| void | fl::transpose_8lane_inline (const u8 *const lanes[8], u8 *output, size_t num_bytes) FL_NOEXCEPT |
| | Low-level bit-interleaving primitive for 8 lanes (ISR-safe)
|
| |
| FASTLED_FORCE_INLINE void | fl::transpose_8strips (const u8 *const input[8], u8 *output, u16 num_leds, u8 bytes_per_led) FL_NOEXCEPT |
| | Transpose 8 LED strips into parallel bit format.
|
| |
| template<typename TSource> |
| void | fl::transpose_generic_inline (const TSource *const lanes[], size_t num_lanes, u8 *output, size_t num_items) FL_NOEXCEPT |
| | Generic bit-interleaving primitive for N lanes with M-bit source data (ISR-safe)
|
| |
| bool | fl::transpose_strips (u8 num_strips, const u8 *const *input, u8 *output, u16 num_leds, u8 bytes_per_led) FL_NOEXCEPT |
| | Helper to transpose N strips with automatic dispatch.
|
| |
| FASTLED_FORCE_INLINE FL_IRAM size_t | fl::transpose_wave8byte_parlio (const u8 *FL_RESTRICT_PARAM laneWaveforms, size_t data_width, u8 *FL_RESTRICT_PARAM outputBuffer) FL_NOEXCEPT |
| |
| template<size_t DATA_WIDTH> |
| FASTLED_FORCE_INLINE FL_IRAM FL_OPTIMIZE_FUNCTION size_t | fl::transpose_wave8byte_parlio_template (const u8 *FL_RESTRICT_PARAM laneWaveforms, u8 *FL_RESTRICT_PARAM outputBuffer) FL_NOEXCEPT |
| | Template specialization of transpose for compile-time data_width (optimization)
|
| |