MayaFlux 0.1.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches
MayaFlux::Nodes::Generator::GeneratorContext Class Reference

Specialized context for generator node callbacks. More...

#include <Generator.hpp>

+ Inheritance diagram for MayaFlux::Nodes::Generator::GeneratorContext:
+ Collaboration diagram for MayaFlux::Nodes::Generator::GeneratorContext:

Public Member Functions

 GeneratorContext (double value, double frequency, float amplitude, double phase)
 Constructs a GeneratorContext with the current generator state.
 
- Public Member Functions inherited from MayaFlux::Nodes::NodeContext
virtual ~NodeContext ()=default
 
template<typename T >
T * as ()
 Safely cast to a derived context type.
 

Public Attributes

double frequency
 Current frequency of the generator.
 
float amplitude
 Current amplitude of the generator.
 
double phase
 Current phase of the generator.
 
- Public Attributes inherited from MayaFlux::Nodes::NodeContext
double value
 Current sample value.
 
std::string type_id
 Type identifier for runtime type checking.
 

Additional Inherited Members

- Protected Member Functions inherited from MayaFlux::Nodes::NodeContext
 NodeContext (double value, const std::string &type)
 Protected constructor for NodeContext.
 

Detailed Description

Specialized context for generator node callbacks.

GeneratorContext extends the base NodeContext to provide detailed information about a generator's current state to callbacks. It includes fundamental oscillator parameters such as frequency, amplitude, and phase that define the generator's behavior at the moment a sample is produced.

This rich context enables callbacks to perform sophisticated analysis and monitoring of generator behavior, such as:

  • Tracking parameter changes over time
  • Implementing frequency-dependent processing
  • Creating visualizations of generator state
  • Synchronizing multiple generators based on phase relationships
  • Implementing adaptive processing based on generator characteristics

Definition at line 24 of file Generator.hpp.


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