SuperpoweredSDK  v2.0.2
Superpowered Audio SDK
Superpowered::Delay Class Reference

Simple delay with minimum memory operations. More...

#include "SuperpoweredDelay.h"

Public Member Functions

 Delay (unsigned int maximumDelayMs, unsigned int maximumSamplerate, unsigned int maximumNumberOfFramesToProcess, unsigned int samplerate)
 Constructor. More...
 
 ~Delay ()
 
const float *const process (float *input, int numberOfFrames, FX *fx=0)
 Processes the audio. More...
 

Public Attributes

float delayMs
 Delay in milliseconds. More...
 
unsigned int samplerate
 Sample rate in Hz. More...
 

Private Member Functions

 Delay (const Delay &)
 
Delayoperator= (const Delay &)
 

Private Attributes

delayInternals * internals
 

Detailed Description

Simple delay with minimum memory operations.

Constructor & Destructor Documentation

◆ Delay() [1/2]

Superpowered::Delay::Delay ( unsigned int  maximumDelayMs,
unsigned int  maximumSamplerate,
unsigned int  maximumNumberOfFramesToProcess,
unsigned int  samplerate 
)

Constructor.

Parameters
maximumDelayMsMaximum delay in milliseconds. Higher values increase memory usage.
maximumSamplerateMaximum sample rate to support. Higher values increase memory usage.
maximumNumberOfFramesToProcessMaximum number of frames for the process() call. Has minimum effect on memory usage.
samplerateThe initial sample rate in Hz.

◆ ~Delay()

Superpowered::Delay::~Delay ( )

◆ Delay() [2/2]

Superpowered::Delay::Delay ( const Delay )
private

Member Function Documentation

◆ operator=()

Delay& Superpowered::Delay::operator= ( const Delay )
private

◆ process()

const float* const Superpowered::Delay::process ( float *  input,
int  numberOfFrames,
FX fx = 0 
)

Processes the audio.

It's never blocking for real-time usage. You can change any properties concurrently with process().

Returns
Returns with a pointer to floating point numbers, which is the output with numberOfFrames audio available in it. It is valid until the next call to process().
Parameters
inputPointer to floating point numbers. 32-bit interleaved stereo input. Special case: set to NULL to empty all buffered content.
numberOfFramesNumber of frames to input and output.
fxOptional. If NULL, then simple memory copy will be used to pass audio from input to the internal buffer. If not NULL, fx->process() will be used to pass audio from input to the internal buffer.

Member Data Documentation

◆ delayMs

float Superpowered::Delay::delayMs

Delay in milliseconds.

◆ internals

delayInternals* Superpowered::Delay::internals
private

◆ samplerate

unsigned int Superpowered::Delay::samplerate

Sample rate in Hz.


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