Signalsmith Audio's DSP Library  1.6.0
Useful C++ classes/templates for audio effects
Static Methods
signalsmith::mix::Hadamard< Sample, size > Class Template Reference

#include <mix.h>

Detailed Description

template<typename Sample, int size = -1>
class signalsmith::mix::Hadamard< Sample, size >

Hadamard: high mixing levels, N log(N) operations.

Static Methods

template<class Data >
static void inPlace (Data &&data)
 Applies the matrix, scaled so it's orthogonal. More...
 
static Sample scalingFactor ()
 Scaling factor applied to make it orthogonal. More...
 
template<class Data , int startIndex = 0>
static void unscaledInPlace (Data &&data)
 Skips the scaling, so it's a matrix full of 1s. More...
 

Method Details

◆ inPlace()

template<typename Sample , int size = -1>
template<class Data >
static void signalsmith::mix::Hadamard< Sample, size >::inPlace ( Data &&  data)
inlinestatic

Applies the matrix, scaled so it's orthogonal.

◆ scalingFactor()

template<typename Sample , int size = -1>
static Sample signalsmith::mix::Hadamard< Sample, size >::scalingFactor ( )
inlinestatic

Scaling factor applied to make it orthogonal.

TODO: test for C++20, or whatever makes this constexpr. Maybe a #define in common.h?

◆ unscaledInPlace()

template<typename Sample , int size = -1>
template<class Data , int startIndex = 0>
static void signalsmith::mix::Hadamard< Sample, size >::unscaledInPlace ( Data &&  data)
inlinestatic

Skips the scaling, so it's a matrix full of 1s.