HOA Library
beta 3.0
High Order Ambisonics Library
|
The vector class computes the energy and the velocity vectors for a set of loudspeakers. More...
#include <Hoa_Vector.hpp>
Public Member Functions | |
Vector (const size_t numberOfChannels) hoa_noexcept | |
The vector constructor. More... | |
virtual | ~Vector () hoa_noexcept=0 |
The vector destructor. More... | |
virtual void | computeRendering () hoa_noexcept=0 |
This method pre-computes the necessary values to process. More... | |
virtual void | process (const T *inputs, T *outputs) hoa_noexcept=0 |
This method computes the energy and velocity vectors. More... | |
virtual void | processVelocity (const T *inputs, T *outputs) hoa_noexcept=0 |
This method computes the velocity vector. More... | |
virtual void | processEnergy (const T *inputs, T *outputs) hoa_noexcept=0 |
This method computes the energy vector. More... | |
Public Member Functions inherited from ProcessorPlanewaves< D, T > | |
ProcessorPlanewaves (const size_t nplws) hoa_noexcept | |
The planewaves constructor. More... | |
virtual | ~ProcessorPlanewaves () hoa_noexcept |
The planewaves destructor. | |
size_t | getNumberOfPlanewaves () const hoa_noexcept |
Returns the number of planewaves. | |
void | setPlanewavesRotation (const T x_axe, const T y_axe, const T z_axe) hoa_noexcept |
Sets the global rotation of the planewaves. More... | |
T | getPlanewavesRotationX () const hoa_noexcept |
Returns the angle of rotation around the x axis in radian of the planewaves. | |
T | getPlanewavesRotationY () const hoa_noexcept |
Returns the angle of rotation around the y axis in radian of the planewaves. | |
T | getPlanewavesRotationZ () const hoa_noexcept |
Returns the angle of rotation around the z axis in radian of the planewaves. | |
size_t | getPlanewaveIndex (const size_t index) hoa_noexcept |
Returns the index of a planewave. | |
void | setPlanewaveAzimuth (const size_t index, const T azimuth) hoa_noexcept |
Sets the azimuth of a planewave in radian. More... | |
void | setPlanewaveElevation (const size_t index, const T elevation) hoa_noexcept |
Sets the azimuth of a planewave in radian. More... | |
T | getPlanewaveAzimuth (const size_t index, const bool rotation=true) const hoa_noexcept |
Returns the azimuth of a planewave. More... | |
T | getPlanewaveElevation (const size_t index, const bool rotation=true) const hoa_noexcept |
Returns the elevation of a planewave. More... | |
T | getPlanewaveAbscissa (const size_t index, const bool rotation=true) const hoa_noexcept |
Returns the abscissa of a planewave. More... | |
T | getPlanewaveOrdinate (const size_t index, const bool rotation=true) const hoa_noexcept |
Returns the ordinate of a planewave. More... | |
T | getPlanewaveHeight (const size_t index, const bool rotation=true) const hoa_noexcept |
Returns the height of a planewave. More... | |
std::string | getPlanewaveName (const size_t index) const hoa_noexcept |
Retruns the name for a planewave. More... | |
Public Member Functions inherited from Processor< D, T > | |
virtual | ~Processor () hoa_noexcept |
The destructor. | |
The vector class computes the energy and the velocity vectors for a set of loudspeakers.
The vector class compute the energy and the velocity vectors of a sound field for a set of channels. It is an useful tool to characterize the quality of the sound field restitution. For further information : Michael A. Gerzon, General metatheorie of auditory localization. Audio Engineering Society Preprint, 3306, 1992. This class retrieve the cartesian coordinates of the vectors.
Definition at line 22 of file Hoa_Vector.hpp.
Vector | ( | const size_t | numberOfChannels | ) |
The vector constructor.
The vector constructor allocates and initialize the member values to computes vectors. The number of channels must be at least 1.
numberOfChannels | The number of channels. |
|
pure virtual |
The vector destructor.
The vector destructor free the memory.
|
pure virtual |
This method pre-computes the necessary values to process.
You should use this method before calling the process methods and after changing the azimuth, the elevation or the offset of the channels.
|
pure virtual |
This method computes the energy and velocity vectors.
You should use this method for in-place or not-in-place processing and sample by sample. The inputs array contains the channels samples and the minimum size must be the number of channels. The outputs array contains the vectors cartesian coordinates and the minimum size must be 4 for 2d and 6 for 3d. The coordinates arrangement in the outputs array is velocity abscissa, velocity ordinate, (velocity height), energy abscissa and energy ordinate (and energy height).
inputs | The inputs array. |
outputs | The outputs array. |
Reimplemented from Processor< D, T >.
|
pure virtual |
This method computes the velocity vector.
You should use this method for in-place or not-in-place processing and sample by sample. The inputs array and contains the channels samples and the minimum size must be the number of channels. The outputs array contains the vectors cartesian coordinates and the minimum size must be 2 for 2d and 3 for 3d. The coordinates arrangement in the outputs array is velocity abscissa and velocity ordinate (and velocity height).
inputs | The inputs array. |
outputs | The outputs array. |
|
pure virtual |
This method computes the energy vector.
You should use this method for in-place or not-in-place processing and sample by sample. The inputs array and contains the channels samples and the minimum size must be the number of harmonics. The outputs array contains the vectors cartesian coordinates and the minimum size must be 2 for 2d and 3 for 3d. The coordinates arrangement in the outputs array is energy abscissa and energy ordinate (and energy height).
inputs | The inputs array. |
outputs | The outputs array. |