SAL
A C++ library for spatial audio.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Member Functions | List of all members
sal::HoaBuffer Class Reference

#include <audiobuffer.h>

Inheritance diagram for sal::HoaBuffer:
sal::Buffer

Public Member Functions

 HoaBuffer (const Int max_degree, const Int num_samples, const HoaOrdering ordering=HoaOrdering::Acn)
 
void SetSample (const Int order, const Int degree, const Int sample_id, const Sample &sample_value) noexcept
 
void AddSamples (const Int order, const Int degree, const Int from_sample_id, const Int num_samples, const Sample *samples)
 
void MultiplyAddSamples (const Int order, const Int degree, const Int from_sample_id, const Int num_samples, const Sample *samples, const Sample constant) noexcept
 
Sample GetSample (const Int order, const Int degree, const Int sample_id) const noexcept
 
- Public Member Functions inherited from sal::Buffer
 Buffer (const Int num_channels, const Int num_samples)
 
 Buffer ()
 
 Buffer (Sample **data_referenced, const Int num_channels, const Int num_samples) noexcept
 
virtual Int num_channels () const noexcept
 
virtual Int num_samples () const noexcept
 
Sample GetSample (Int channel_id, Int sample_id) const noexcept
 
bool IsDataOwner () const noexcept
 
void SetSample (const Int channel_id, const Int sample_id, const Sample sample) noexcept
 
void SetSamples (const Int channel_id, const Int from_sample_id, const Int num_samples, const Sample *samples) noexcept
 
void SetSamples (const Buffer &other) noexcept
 
void AddSamples (const Int channel_id, const Int from_sample_id, const Int num_samples, const Sample *samples) noexcept
 
void MultiplyAddSamples (const Int channel_id, const Int from_sample_id, const Int num_samples, const Sample *samples, const Sample constant) noexcept
 
void FilterAddSamples (const Int channel_id, const Int from_sample_id, const Int num_samples, const Sample *samples, mcl::DigitalFilter &filter) noexcept
 
const SampleGetReadPointer (const Int channel_id) const noexcept
 
SampleGetWritePointer (const Int channel_id) noexcept
 
Sample ** GetWritePointers () noexcept
 
virtual void AddSamples (const Buffer &buffer) noexcept
 
void SetFrame (const Int channel_id, const Int frame_id, const Int frame_length, const Signal &signal)
 
void PrintData ()
 
virtual void Reset () noexcept
 
 Buffer (const Buffer &other)
 
Bufferoperator= (const Buffer &other)
 
virtual ~Buffer ()
 

Static Public Member Functions

static Int GetChannelId (const Int order, const Int degree, const HoaOrdering ordering)
 
static Int GetNumChannels (const Int max_order)
 
- Static Public Member Functions inherited from sal::Buffer
static bool Test ()
 

Additional Inherited Members

- Public Types inherited from sal::Buffer
enum  ChannelLabels { kMonoChannel = 0, kLeftChannel = 0, kRightChannel = 1 }
 

Constructor & Destructor Documentation

sal::HoaBuffer::HoaBuffer ( const Int  max_degree,
const Int  num_samples,
const HoaOrdering  ordering = HoaOrdering::Acn 
)
inline

Member Function Documentation

void sal::HoaBuffer::AddSamples ( const Int  order,
const Int  degree,
const Int  from_sample_id,
const Int  num_samples,
const Sample samples 
)
inline
static Int sal::HoaBuffer::GetChannelId ( const Int  order,
const Int  degree,
const HoaOrdering  ordering 
)
inlinestatic
static Int sal::HoaBuffer::GetNumChannels ( const Int  max_order)
inlinestatic
Sample sal::HoaBuffer::GetSample ( const Int  order,
const Int  degree,
const Int  sample_id 
) const
inlinenoexcept
void sal::HoaBuffer::MultiplyAddSamples ( const Int  order,
const Int  degree,
const Int  from_sample_id,
const Int  num_samples,
const Sample samples,
const Sample  constant 
)
inlinenoexcept

This first multiplies all the input samples by a certain constant and then adds the result to the samples in the buffer.

void sal::HoaBuffer::SetSample ( const Int  order,
const Int  degree,
const Int  sample_id,
const Sample sample_value 
)
inlinenoexcept

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