WS2812 RMT Driver
API reference
Loading...
Searching...
No Matches
Public Member Functions | List of all members
WS2812MultiAnimator Class Reference

#include <ws2812_multi_animator.hpp>

Public Member Functions

 WS2812MultiAnimator (const std::vector< WS2812Strip * > &strips, bool unified=true, bool sync=true)
 Construct from a list of strips.
 
void SetEffect (WS2812Animator::Effect effect, uint32_t color=0xFFFFFF)
 Apply an effect to all managed strips.
 
void SetEffect (size_t index, WS2812Animator::Effect effect, uint32_t color=0xFFFFFF)
 Apply an effect to a single strip.
 
void Tick ()
 Advance all animations by one step.
 

Constructor & Destructor Documentation

◆ WS2812MultiAnimator()

WS2812MultiAnimator::WS2812MultiAnimator ( const std::vector< WS2812Strip * > &  strips,
bool  unified = true,
bool  sync = true 
)
explicit

Construct from a list of strips.

Parameters
stripsPointers to WS2812Strip objects.
unifiedIf true all strips share the longest length.
syncIf true keep animation steps in sync.

Member Function Documentation

◆ SetEffect() [1/2]

void WS2812MultiAnimator::SetEffect ( size_t  index,
WS2812Animator::Effect  effect,
uint32_t  color = 0xFFFFFF 
)

Apply an effect to a single strip.

Parameters
indexIndex of the strip.
effectDesired animation effect.
colorBase colour for the effect.

◆ SetEffect() [2/2]

void WS2812MultiAnimator::SetEffect ( WS2812Animator::Effect  effect,
uint32_t  color = 0xFFFFFF 
)

Apply an effect to all managed strips.

◆ Tick()

void WS2812MultiAnimator::Tick ( )

Advance all animations by one step.


The documentation for this class was generated from the following files: