ESPHome  2024.12.2
Public Member Functions | Protected Attributes
esphome::light::AddressableLightTransformer Class Reference

#include <addressable_light.h>

Inheritance diagram for esphome::light::AddressableLightTransformer:
esphome::light::LightTransitionTransformer esphome::light::LightTransformer

Public Member Functions

 AddressableLightTransformer (AddressableLight &light)
 
void start () override
 
optional< LightColorValuesapply () override
 
- Public Member Functions inherited from esphome::light::LightTransitionTransformer
void start () override
 
optional< LightColorValuesapply () override
 
- Public Member Functions inherited from esphome::light::LightTransformer
virtual ~LightTransformer ()=default
 
void setup (const LightColorValues &start_values, const LightColorValues &target_values, uint32_t length)
 
virtual bool is_finished ()
 Indicates whether this transformation is finished. More...
 
virtual void stop ()
 This will be called after transition is finished. More...
 
const LightColorValuesget_start_values () const
 
const LightColorValuesget_target_values () const
 

Protected Attributes

AddressableLightlight_
 
Color target_color_ {}
 
float last_transition_progress_ {0.0f}
 
float accumulated_alpha_ {0.0f}
 
- Protected Attributes inherited from esphome::light::LightTransitionTransformer
bool changing_color_mode_ {false}
 
LightColorValues end_values_ {}
 
LightColorValues intermediate_values_ {}
 
- Protected Attributes inherited from esphome::light::LightTransformer
uint32_t start_time_
 
uint32_t length_
 
LightColorValues start_values_
 
LightColorValues target_values_
 

Additional Inherited Members

- Protected Member Functions inherited from esphome::light::LightTransformer
float get_progress_ ()
 The progress of this transition, on a scale of 0 to 1. More...
 
- Static Protected Member Functions inherited from esphome::light::LightTransitionTransformer
static float smoothed_progress (float x)
 

Detailed Description

Definition at line 108 of file addressable_light.h.

Constructor & Destructor Documentation

◆ AddressableLightTransformer()

esphome::light::AddressableLightTransformer::AddressableLightTransformer ( AddressableLight light)
inline

Definition at line 110 of file addressable_light.h.

Member Function Documentation

◆ apply()

optional< LightColorValues > esphome::light::AddressableLightTransformer::apply ( )
overridevirtual

Implements esphome::light::LightTransformer.

Definition at line 64 of file addressable_light.cpp.

◆ start()

void esphome::light::AddressableLightTransformer::start ( )
overridevirtual

Reimplemented from esphome::light::LightTransformer.

Definition at line 51 of file addressable_light.cpp.

Field Documentation

◆ accumulated_alpha_

float esphome::light::AddressableLightTransformer::accumulated_alpha_ {0.0f}
protected

Definition at line 119 of file addressable_light.h.

◆ last_transition_progress_

float esphome::light::AddressableLightTransformer::last_transition_progress_ {0.0f}
protected

Definition at line 118 of file addressable_light.h.

◆ light_

AddressableLight& esphome::light::AddressableLightTransformer::light_
protected

Definition at line 116 of file addressable_light.h.

◆ target_color_

Color esphome::light::AddressableLightTransformer::target_color_ {}
protected

Definition at line 117 of file addressable_light.h.


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