HoaLibrary
2.0
High Order Ambisonics Library
|
The ambisonic class. More...
#include <Ambisonic.h>
Public Member Functions | |
Ambisonic (unsigned int order) | |
The ambisonic constructor. More... | |
~Ambisonic () | |
The ambisonic destructor. More... | |
unsigned int | getOrder () const |
Retrieve the decomposition order. More... | |
unsigned int | getNumberOfHarmonics () const |
Retrieve the number of harmonics. More... | |
int | getHarmonicArgument (const unsigned int index) const |
Retrieve the argument of an harmonic. More... | |
unsigned int | getHarmonicBand (const unsigned int index) const |
Retrieve the band of an harmonic. More... | |
std::string | getHarmonicsName (const unsigned int index) const |
Retrieve a name for an harmonic. More... | |
The ambisonic class.
The ambisonics classes inherit from this classe. It computes the number of harmonics depending of the decomposition order and sorts the arguments and the bands of the harmonics in arrays.
Definition at line 21 of file Ambisonic.h.
Hoa3D::Ambisonic::Ambisonic | ( | unsigned int | order | ) |
The ambisonic constructor.
The ambisonic constructor allocates and initializes the generale member values depending of a decomposition order. The order must be at least 1.
order | The order. |
Definition at line 11 of file Ambisonic.cpp.
Hoa3D::Ambisonic::~Ambisonic | ( | ) |
The ambisonic destructor.
The ambisonic destructor free the memory.
Definition at line 30 of file Ambisonic.cpp.
|
inline |
Retrieve the argument of an harmonic.
The argument of an harmonic is in the range -band to band. The harmonics are sorted by their bands, from 0 to the decomposition order. In each band contains 2 * band + 1 harmonics, sorted by their arguments in the range -band to band. The harmonic input and output arrays in process method of ambisonic classes must have this configuration. For the first bands, the harmonics arrangement is h[0, 0] h[1, 0] h[1, -1] h[1, 1] h[2, 0] h[2, -1] h[2, 1] h[2, -2] h[2, 2] etc. with h[band, argument].
index | The global index of an harmonic. |
Definition at line 63 of file Ambisonic.h.
|
inline |
Retrieve the band of an harmonic.
The bands of the harmonics are in the range 0 to the decomposition order. Each band contains 2 * band + 1 harmonics in the range -band to band. The harmonic input and output arrays in process method of ambisonic classes must have this configuration. For the first bands, the harmonics arrangement is h[0, 0] h[1, 0] h[1, -1] h[1, 1] h[2, 0] h[2, -1] h[2, 1] h[2, -2] h[2, 2] etc. with h[band, argument].
index | The global index of an harmonic. |
Definition at line 79 of file Ambisonic.h.
|
inline |
Retrieve a name for an harmonic.
Retrieve a name for an harmonic in a std::string format that will be "harmonic band argument".
index | The global index of an harmonic. |
Definition at line 93 of file Ambisonic.h.
|
inline |
Retrieve the number of harmonics.
Retrieve the number of harmonics of an ambisonic class.
Definition at line 51 of file Ambisonic.h.
|
inline |
Retrieve the decomposition order.
Retrieve the decomposition order of an ambisonic class.
Definition at line 46 of file Ambisonic.h.