Klang C++
Language Reference (draft)
|
Applies a function to a signal (input-output) More...
#include <klang.h>
Public Member Functions | |
virtual | ~Function () |
operator SIGNAL () | |
operator param () | |
unsigned int | args () const |
template<typename First , typename... Rest> | |
std::tuple< Rest... > | tail (const std::tuple< First, Rest... > &t) const |
template<typename FunctionPtr > | |
Function () | |
template<typename FunctionPtr > | |
Function (FunctionPtr function) | |
template<typename FunctionPtr , typename... OtherArgs> | |
Function (FunctionPtr function, OtherArgs... args) | |
void | input () override |
template<typename First , typename... Rest> | |
First | first (First first, Rest...) |
template<typename... FuncArgs> | |
Function< SIGNAL, Args... > & | operator() (const FuncArgs &... args) |
template<typename... FuncArgs> | |
const float | operator() (const FuncArgs &... args) const |
template<typename... FuncArgs> | |
Function< SIGNAL, Args... > & | with (FuncArgs... args) |
signal | evaluate () const |
virtual void | process () override |
klang::Graph & | operator>> (klang::Graph &graph) |
klang::GraphPtr & | operator>> (klang::GraphPtr &graph) |
operator const SIGNAL & () override | |
operator const SIGNAL & () const override | |
template<typename... params> | |
Modifier< SIGNAL > & | operator() (params... p) |
virtual const SIGNAL & | input () const |
virtual void | input (const SIGNAL &source) |
virtual void | operator<< (const SIGNAL &source) |
virtual const SIGNAL & | output () const |
template<typename TYPE > | |
TYPE & | operator>> (TYPE &destination) |
template<typename TYPE > | |
SIGNAL | operator+ (TYPE &other) |
template<typename TYPE > | |
SIGNAL | operator* (TYPE &other) |
template<typename TYPE > | |
SIGNAL | operator- (TYPE &other) |
template<typename TYPE > | |
SIGNAL | operator/ (TYPE &other) |
Public Attributes | |
std::function< float(Args...)> | function |
std::tuple< Args... > | inputs |
SIGNAL | in = { 0.f } |
SIGNAL | out = { 0.f } |
Static Public Attributes | |
static constexpr unsigned int | ARGS = sizeof...(Args) |
|
inlinevirtual |
|
inline |
|
inline |
|
inline |
Definition at line 1539 of file klang.h.
|
inline |
|
inline |
Definition at line 1608 of file klang.h.
References klang::Generic::Function< SIGNAL, Args >::ARGS, and klang::Generic::Function< SIGNAL, Args >::inputs.
Referenced by klang::Generic::Function< SIGNAL, Args >::process().
|
inline |
|
inlineoverridevirtual |
Reimplemented from klang::Generic::Input< SIGNAL >.
Definition at line 1544 of file klang.h.
References klang::Generic::Function< SIGNAL, Args >::inputs.
|
inlinevirtualinherited |
Reimplemented in klang::Generic::Graph< SIZE >::Series.
Definition at line 1343 of file klang.h.
References klang::Generic::Input< SIGNAL >::in.
|
inlinevirtualinherited |
Definition at line 1347 of file klang.h.
References klang::Generic::Input< SIGNAL >::in.
Referenced by klang::Effect::process(), and klang::Stereo::Effect::process().
|
inlineoverridevirtualinherited |
|
inlineoverridevirtualinherited |
Reimplemented from klang::Generic::Output< SIGNAL >.
Definition at line 1449 of file klang.h.
References klang::Generic::Modifier< SIGNAL >::process().
|
inline |
|
inline |
|
inline |
Definition at line 1554 of file klang.h.
References klang::Generic::Function< SIGNAL, Args >::ARGS, and klang::Generic::Function< SIGNAL, Args >::inputs.
|
inline |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
|
inlinevirtualinherited |
Definition at line 1346 of file klang.h.
References klang::Generic::Input< SIGNAL >::in.
|
inline |
|
inline |
|
inlineinherited |
Definition at line 1364 of file klang.h.
References klang::Generic::Output< SIGNAL >::out, and klang::Generic::Output< SIGNAL >::process().
|
inlinevirtualinherited |
|
inlineoverridevirtual |
Reimplemented from klang::Generic::Modifier< SIGNAL >.
Definition at line 1617 of file klang.h.
References klang::Generic::Function< SIGNAL, Args >::evaluate().
|
inline |
|
inline |
|
staticconstexpr |
Definition at line 1520 of file klang.h.
Referenced by klang::Generic::Function< SIGNAL, Args >::evaluate(), and klang::Generic::Function< SIGNAL, Args >::operator()().
std::function<float(Args...)> klang::Generic::Function< SIGNAL, Args >::function |
|
inherited |
Definition at line 1340 of file klang.h.
Referenced by klang::Generic::Input< SIGNAL >::input(), klang::Generic::Input< SIGNAL >::input(), and klang::Generic::Input< SIGNAL >::operator<<().
std::tuple<Args...> klang::Generic::Function< SIGNAL, Args >::inputs |
Definition at line 1523 of file klang.h.
Referenced by klang::Generic::Function< SIGNAL, Args >::evaluate(), klang::Generic::Function< SIGNAL, Args >::input(), and klang::Generic::Function< SIGNAL, Args >::operator()().
|
inherited |
Definition at line 1357 of file klang.h.
Referenced by klang::Generic::Output< SIGNAL >::operator const SIGNAL &(), klang::Generic::Output< SIGNAL >::operator const SIGNAL &(), klang::Generic::Output< SIGNAL >::operator>>(), and klang::Generic::Output< SIGNAL >::output().