Ardour  9.0-pre0-582-g084a23a80d
VectorSink< T > Class Template Reference

#include <utils.h>

Inheritance diagram for VectorSink< T >:
[legend]

Public Member Functions

virtual void process (AudioGrapher::ProcessContext< T > const &c)
 
void process (AudioGrapher::ProcessContext< T > &c)
 
std::vector< T > const & get_data () const
 
T const * get_array () const
 
void reset ()
 
- Public Member Functions inherited from AudioGrapher::Sink< T >
virtual ~Sink ()
 

Protected Attributes

std::vector< T > data
 

Detailed Description

template<typename T>
class VectorSink< T >

Definition at line 65 of file libs/audiographer/tests/utils.h.

Member Function Documentation

◆ get_array()

template<typename T >
T const* VectorSink< T >::get_array ( ) const
inline

Definition at line 78 of file libs/audiographer/tests/utils.h.

◆ get_data()

template<typename T >
std::vector<T> const& VectorSink< T >::get_data ( ) const
inline

Definition at line 77 of file libs/audiographer/tests/utils.h.

◆ process() [1/2]

template<typename T >
void VectorSink< T >::process ( AudioGrapher::ProcessContext< T > &  context)
inlinevirtual

Process given data Data may be modified, so in place processing is allowed. The default implementation calls the non-modifying version, so this function does not need to be overridden. However, if the sink can do in-place processing, overriding this is highly recommended.

If this is not overridden adding "using Sink<T>::process;" to the deriving class declaration is suggested to avoid warnings about hidden virtual functions.

Reimplemented from AudioGrapher::Sink< T >.

Definition at line 74 of file libs/audiographer/tests/utils.h.

◆ process() [2/2]

template<typename T >
virtual void VectorSink< T >::process ( AudioGrapher::ProcessContext< T > const &  context)
inlinevirtual

Process given data. The data can not be modified, so in-place processing is not allowed. At least this function must be implemented by deriving classes

Implements AudioGrapher::Sink< T >.

Reimplemented in AppendingVectorSink< T >.

Definition at line 68 of file libs/audiographer/tests/utils.h.

◆ reset()

template<typename T >
void VectorSink< T >::reset ( )
inline

Definition at line 79 of file libs/audiographer/tests/utils.h.

Member Data Documentation

◆ data

template<typename T >
std::vector<T> VectorSink< T >::data
protected

Definition at line 82 of file libs/audiographer/tests/utils.h.


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