eDSP  0.0.1
A cross-platform DSP library written in C++.
Public Types | Public Member Functions | List of all members
edsp::feature::temporal::leq< T > Class Template Reference

This class estimates the Equivalent Continuous Sound Level over consecutive frames. More...

#include <leq.hpp>

Public Types

using size_type = std::size_t
 
using value_type = T
 

Public Member Functions

 leq (size_type number_frames)
 Creates a leq estimator. More...
 
 ~leq ()=default
 Default destructor. More...
 
template<typename ForwardIt >
value_type extract (ForwardIt first, ForwardIt last)
 

Detailed Description

template<typename T>
class edsp::feature::temporal::leq< T >

This class estimates the Equivalent Continuous Sound Level over consecutive frames.

Leq is the preferred method to describe sound levels that vary over time, resulting in a single decibel value which takes into account the total sound energy over the period of time of interest

Member Typedef Documentation

◆ size_type

template<typename T>
using edsp::feature::temporal::leq< T >::size_type = std::size_t

◆ value_type

template<typename T>
using edsp::feature::temporal::leq< T >::value_type = T

Constructor & Destructor Documentation

◆ leq()

template<typename T >
edsp::feature::temporal::leq< T >::leq ( leq< T >::size_type  number_frames)
inlineexplicit

Creates a leq estimator.

Parameters
number_framesNumber of frames over time of interest to compute the equivalent sound level.

◆ ~leq()

template<typename T>
edsp::feature::temporal::leq< T >::~leq ( )
default

Default destructor.

Member Function Documentation

◆ extract()

template<typename T >
template<typename ForwardIt >
leq< T >::value_type edsp::feature::temporal::leq< T >::extract ( ForwardIt  first,
ForwardIt  last 
)
inline

Estimates the equivalent sound level over time of the frame represented by the elements in the range [first, last).

Note
Frames can have different lengths but it is preferable to keep consistency between consecutive frames.
Parameters
firstForward iterator defining the begin of the range to examine.
lastForward iterator defining the end of the range to examine.
Returns
The estimated equivalent sound level in dB.

The documentation for this class was generated from the following file: