Loading [MathJax]/extensions/tex2jax.js
HoaLibrary  2.0
High Order Ambisonics Library
All Classes Namespaces Functions Enumerations Enumerator
Public Member Functions | List of all members
Hoa2D::Meter Class Reference

The planewaves peak level meter. More...

#include <Meter.h>

Inheritance diagram for Hoa2D::Meter:
Hoa2D::Planewaves

Public Member Functions

 Meter (unsigned int number_of_channels)
 The meter constructor. More...
 
 ~Meter ()
 The meter destructor. More...
 
void setChannelAzimuth (unsigned int index, double azimuth)
 Set the azimuth of a given channel. More...
 
void setChannelsAzimuth (double *azimuth)
 Set the azimtuh of all the channels. More...
 
double getChannelAzimuthMapped (unsigned int index) const
 Get the mapped azimuth of a given channel. More...
 
double getChannelWidth (unsigned int index) const
 Get the width of a given channel. More...
 
void setVectorSize (unsigned int vectorSize)
 Set the vector size. More...
 
unsigned int getVectorSize (unsigned int vectorSize) const
 Get the vector size. More...
 
double getChannelPeak (unsigned int index) const
 Retrieve the peak value of a given channel. More...
 
double getChannelEnergy (unsigned int index) const
 Retrieve the energy of a given channel. More...
 
void process (const float *inputs)
 This method performs the metering with single precision. More...
 
void process (const double *inputs)
 This method performs the metering with double precision. More...
 
- Public Member Functions inherited from Hoa2D::Planewaves
 Planewaves (unsigned int numberOfChannels)
 The planewaves constructor. More...
 
 ~Planewaves ()
 The planewaves destructor. More...
 
unsigned int getNumberOfChannels () const
 Retrieve the number of channels. More...
 
double getChannelAzimuth (unsigned int index) const
 Retrieve the azimuth of a channel. More...
 
double getChannelAbscissa (unsigned int index) const
 Retrieve the abscissa of a channel. More...
 
double getChannelOrdinate (unsigned int index) const
 Retrieve the ordinate of a channel. More...
 
std::string getChannelName (unsigned int index)
 Retrieve a name for a channel. More...
 

Additional Inherited Members

- Protected Member Functions inherited from Hoa2D::Planewaves
void setChannelAzimuth (unsigned int index, double azimuth)
 Set the azimuth of a channel. More...
 
void setChannelsAzimuth (double *azimuths)
 Set the azimtuh of all the channels. More...
 

Detailed Description

The planewaves peak level meter.

The meter should be used to compute and display channels peak levels.

Definition at line 18 of file Meter.h.

Constructor & Destructor Documentation

Hoa2D::Meter::Meter ( unsigned int  number_of_channels)

The meter constructor.

The meter constructor allocates and initialize the member values.
Parameters
number_of_channelsThe number of channels.

Definition at line 11 of file Meter.cpp.

Hoa2D::Meter::~Meter ( )

The meter destructor.

The meter destructor free the memory.

Definition at line 107 of file Meter.cpp.

Member Function Documentation

double Hoa2D::Meter::getChannelAzimuthMapped ( unsigned int  index) const
inline

Get the mapped azimuth of a given channel.

Parameters
indexThe index of the channel.
Returns
The mapped azimuth.
See Also
getChannelAzimuth, getChannelAzimuthMapped

Definition at line 67 of file Meter.h.

double Hoa2D::Meter::getChannelEnergy ( unsigned int  index) const
inline

Retrieve the energy of a given channel.

Parameters
indexThe index of the channel.
See Also
getChannelPeak

Definition at line 116 of file Meter.h.

double Hoa2D::Meter::getChannelPeak ( unsigned int  index) const
inline

Retrieve the peak value of a given channel.

Parameters
indexThe index of the channel.
See Also
getChannelEnergy

Definition at line 105 of file Meter.h.

double Hoa2D::Meter::getChannelWidth ( unsigned int  index) const
inline

Get the width of a given channel.

Parameters
indexThe index of the channel.
Returns
The channel width.
See Also
getChannelAzimuth, getChannelAzimuthMapped

Definition at line 80 of file Meter.h.

unsigned int Hoa2D::Meter::getVectorSize ( unsigned int  vectorSize) const
inline

Get the vector size.

Parameters
vectorSizeThe vector size.
See Also
setVectorSize

Definition at line 98 of file Meter.h.

void Hoa2D::Meter::process ( const float *  inputs)

This method performs the metering with single precision.

You should use this method for in-place or not-in-place processing and performs the metering sample by sample. The inputs array contains channels samples and the minimum size must be the number of channels.

Parameters
inputsThe inputs array.

Definition at line 67 of file Meter.cpp.

void Hoa2D::Meter::process ( const double *  inputs)

This method performs the metering with double precision.

You should use this method for in-place or not-in-place processing and performs the metering sample by sample. The inputs array contains channels samples and the minimum size must be the number of channels.

Parameters
inputsThe inputs array.

Definition at line 87 of file Meter.cpp.

void Hoa2D::Meter::setChannelAzimuth ( unsigned int  index,
double  azimuth 
)

Set the azimuth of a given channel.

Set the azimuth of a given channel. The azimuth is in radian between 0 and 2 Pi, O is the front of the soundfield and Pi is the back of the sound field.

Parameters
indexThe index of the channel.
azimuthThe azimuth.
See Also
getChannelAzimuth

Definition at line 27 of file Meter.cpp.

void Hoa2D::Meter::setChannelsAzimuth ( double *  azimuth)

Set the azimtuh of all the channels.

Set the azimtuh of all the channels. The azimuths are in radian between 0 and 2 Pi, O is the front of the soundfield and Pi is the back of the sound field. The azimtuhs array must have a minimum size of the number of channels.

Parameters
azimuthsThe azimuths array.
See Also
setChannelAzimuth

Definition at line 33 of file Meter.cpp.

void Hoa2D::Meter::setVectorSize ( unsigned int  vectorSize)

Set the vector size.

Parameters
vectorSizeThe vector size.
See Also
getChannelAzimuth

Definition at line 21 of file Meter.cpp.