NAP
Public Member Functions | Protected Member Functions | List of all members
Process Class Referenceabstract

#include <audio/core/process.h>

Public Member Functions

 Process (NodeManager &nodeManager)
 
 Process (ParentProcess &parent)
 
 Process (const Process &)=delete
 
Processoperator= (const Process &)=delete
 
virtual ~Process ()
 
void update ()
 
NodeManagergetNodeManager () const
 
int getBufferSize () const
 
float getSampleRate () const
 
DiscreteTimeValue getSampleTime () const
 

Protected Member Functions

virtual void sampleRateChanged (float sampleRate)
 
virtual void bufferSizeChanged (int bufferSize)
 
bool isRegisteredWithNodeManager () const
 

Description

A process that is executed once on every audio callback on the audio thread. Processes can be child processes to parent processes that run their child processes. Base class to Node.

Inheritance diagram for Process:
[legend]

Constructor & Destructor Documentation

◆ Process() [1/3]

Process ( NodeManager nodeManager)

Constructor

Parameters
nodeManagerthe node manager this process runs on.

◆ Process() [2/3]

Process ( ParentProcess parent)

Constructor that takes a parent process.

◆ Process() [3/3]

Process ( const Process )
delete

◆ ~Process()

virtual ~Process ( )
virtual

Member Function Documentation

◆ bufferSizeChanged()

virtual void bufferSizeChanged ( int  bufferSize)
protectedvirtual

Called whenever the buffersize that the node system runs on changes. Can be overwriten to respond to changes.

Parameters
bufferSizethe new buffersize

◆ getBufferSize()

int getBufferSize ( ) const

Returns the internal buffersize of the node system that this process belongs to. Output is being pulled through the graph buffers of this size at a time. Not to be confused with the buffersize that the audio callback runs on!

◆ getNodeManager()

NodeManager& getNodeManager ( ) const
Returns
: The node manager that this process is processed on

◆ getSampleRate()

float getSampleRate ( ) const

Returns the sample rate that the node system runs on

◆ getSampleTime()

DiscreteTimeValue getSampleTime ( ) const

Returns the current time in samples

◆ isRegisteredWithNodeManager()

bool isRegisteredWithNodeManager ( ) const
protected
Returns
true if the node is currently registered with a currently existing node manager.

◆ operator=()

Process& operator= ( const Process )
delete

◆ sampleRateChanged()

virtual void sampleRateChanged ( float  sampleRate)
protectedvirtual

Called whenever the sample rate that the node system runs on changes. Can be overwritten to respond to changes

Parameters
sampleRatethen new sample rate

Reimplemented in LevelMeterNode.

◆ update()

void update ( )