Ardour  9.0-pre0-582-g084a23a80d
AudioGrapher::Normalizer Class Reference

A class for normalizing to a specified target in dB. More...

#include <normalizer.h>

Inheritance diagram for AudioGrapher::Normalizer:
[legend]

Public Member Functions

 Normalizer (float target_dB, samplecnt_t)
 Constructs a normalizer with a specific target in dB
RT safe. More...
 
 ~Normalizer ()
 
float set_peak (float peak)
 Sets the peak found in the material to be normalized. More...
 
void process (ProcessContext< float > const &c)
 Process a const ProcessContext. More...
 
void process (ProcessContext< float > &c)
 Process a non-const ProcsesContext in-place
RT safe. More...
 
- Public Member Functions inherited from AudioGrapher::ListedSource< float >
void add_output (typename Source< float >::SinkPtr output)
 
void clear_outputs ()
 Removes all outputs added. More...
 
void remove_output (typename Source< float >::SinkPtr output)
 
- Public Member Functions inherited from AudioGrapher::Source< T >
virtual ~Source ()
 
virtual void add_output (SinkPtr output)=0
 Adds an output to this source. All data generated is forwarded to output. More...
 
virtual void remove_output (SinkPtr output)=0
 Removes a specific output from this source. More...
 
- Public Member Functions inherited from AudioGrapher::Sink< float >
virtual ~Sink ()
 

Private Attributes

bool enabled
 
float target
 
float gain
 
float * buffer
 
samplecnt_t buffer_size
 

Additional Inherited Members

- Public Types inherited from AudioGrapher::Source< T >
typedef std::shared_ptr< Sink< T > > SinkPtr
 
- Protected Types inherited from AudioGrapher::ListedSource< float >
typedef std::list< typename Source< float >::SinkPtrSinkList
 
- Protected Member Functions inherited from AudioGrapher::ListedSource< float >
void output (ProcessContext< float > const &c)
 Helper for derived classes. More...
 
void output (ProcessContext< float > &c)
 
bool output_size_is_one ()
 
- Protected Member Functions inherited from AudioGrapher::Throwing< L >
 Throwing ()
 
bool throw_level (ThrowLevel level)
 
- Protected Attributes inherited from AudioGrapher::ListedSource< float >
SinkList outputs
 

Detailed Description

A class for normalizing to a specified target in dB.

Definition at line 13 of file normalizer.h.

Constructor & Destructor Documentation

◆ Normalizer()

AudioGrapher::Normalizer::Normalizer ( float  target_dB,
samplecnt_t   
)

Constructs a normalizer with a specific target in dB
RT safe.

◆ ~Normalizer()

AudioGrapher::Normalizer::~Normalizer ( )

Member Function Documentation

◆ process() [1/2]

void AudioGrapher::Normalizer::process ( ProcessContext< float > &  c)
virtual

Process a non-const ProcsesContext in-place
RT safe.

Reimplemented from AudioGrapher::Sink< float >.

◆ process() [2/2]

void AudioGrapher::Normalizer::process ( ProcessContext< float > const &  c)
virtual

Process a const ProcessContext.

See also
alloc_buffer()
RT safe

Implements AudioGrapher::Sink< float >.

◆ set_peak()

float AudioGrapher::Normalizer::set_peak ( float  peak)

Sets the peak found in the material to be normalized.

See also
PeakReader
RT safe

Member Data Documentation

◆ buffer

float* AudioGrapher::Normalizer::buffer
private

Definition at line 37 of file normalizer.h.

◆ buffer_size

samplecnt_t AudioGrapher::Normalizer::buffer_size
private

Definition at line 38 of file normalizer.h.

◆ enabled

bool AudioGrapher::Normalizer::enabled
private

Definition at line 33 of file normalizer.h.

◆ gain

float AudioGrapher::Normalizer::gain
private

Definition at line 35 of file normalizer.h.

◆ target

float AudioGrapher::Normalizer::target
private

Definition at line 34 of file normalizer.h.


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