ESPHome  2024.11.0
Public Member Functions | Static Protected Member Functions | Protected Attributes
esphome::light::LightTransitionTransformer Class Reference

#include <transformers.h>

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

Public Member Functions

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
 

Static Protected Member Functions

static float smoothed_progress (float x)
 

Protected Attributes

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...
 

Detailed Description

Definition at line 12 of file transformers.h.

Member Function Documentation

◆ apply()

optional<LightColorValues> esphome::light::LightTransitionTransformer::apply ( )
inlineoverridevirtual

Implements esphome::light::LightTransformer.

Definition at line 38 of file transformers.h.

◆ smoothed_progress()

static float esphome::light::LightTransitionTransformer::smoothed_progress ( float  x)
inlinestaticprotected

Definition at line 60 of file transformers.h.

◆ start()

void esphome::light::LightTransitionTransformer::start ( )
inlineoverridevirtual

Reimplemented from esphome::light::LightTransformer.

Definition at line 14 of file transformers.h.

Field Documentation

◆ changing_color_mode_

bool esphome::light::LightTransitionTransformer::changing_color_mode_ {false}
protected

Definition at line 62 of file transformers.h.

◆ end_values_

LightColorValues esphome::light::LightTransitionTransformer::end_values_ {}
protected

Definition at line 63 of file transformers.h.

◆ intermediate_values_

LightColorValues esphome::light::LightTransitionTransformer::intermediate_values_ {}
protected

Definition at line 64 of file transformers.h.


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