MayaFlux 0.2.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ Polynomial() [1/3]

MayaFlux::Nodes::Generator::Polynomial::Polynomial ( const std::vector< double > &  coefficients)
explicit

Constructs a Polynomial generator in direct mode with coefficient-based definition.

Parameters
coefficientsVector of polynomial coefficients (highest power first)

Creates a polynomial generator that evaluates a standard polynomial function defined by the provided coefficients. The coefficients are ordered from highest power to lowest (e.g., [2, 3, 1] represents 2x² + 3x + 1).

Definition at line 5 of file Polynomial.cpp.

7 , m_coefficients(coefficients)
8 , m_scale_factor(1.F)
11{
13}
PolynomialMode m_mode
Converts coefficient vector to a polynomial function.
DirectFunction create_polynomial_function(const std::vector< double > &coefficients)
Creates a polynomial function from coefficients.
double m_scale_factor
Scaling factor for output.
size_t m_buffer_size
Maximum size of the buffers.
DirectFunction m_direct_function
Function for direct mode.
std::vector< double > m_coefficients
Polynomial coefficients (if using coefficient-based definition)
std::span< const float > get_gpu_data_buffer() const
Provides access to the GPU data buffer.
Definition Node.cpp:78
@ DIRECT
Evaluates f(x) where x is the current phase/input.