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

White noise + filter. More...

#include "SuperpoweredWhoosh.h"

Inheritance diagram for Superpowered::Whoosh:
Collaboration diagram for Superpowered::Whoosh:

Public Member Functions

 Whoosh (unsigned int samplerate)
 Constructor. More...
 
 ~Whoosh ()
 
bool process (float *input, float *output, unsigned int numberOfFrames)
 Processes the audio. More...
 

Public Attributes

bool enabled = false
 Turns the effect on/off. The actual switch will happen on the next process() call for smooth, audio-artifact free operation. More...
 
float frequency
 Limited to >= 20 and <= 20000. More...
 
unsigned int samplerate = 0
 Sample rate in Hz. More...
 
float wet
 Limited to >= 0 and <= 1. More...
 

Private Member Functions

 Whoosh (const Whoosh &)
 
Whooshoperator= (const Whoosh &)
 

Private Attributes

whooshInternals * internals
 

Detailed Description

White noise + filter.

One whoosh instance allocates around 4 kb memory.

Constructor & Destructor Documentation

◆ Whoosh() [1/2]

Superpowered::Whoosh::Whoosh ( unsigned int  samplerate)

Constructor.

Enabled is false by default.

Parameters
samplerateThe initial sample rate in Hz.

◆ ~Whoosh()

Superpowered::Whoosh::~Whoosh ( )

◆ Whoosh() [2/2]

Superpowered::Whoosh::Whoosh ( const Whoosh )
private

Member Function Documentation

◆ operator=()

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

◆ process()

bool Superpowered::Whoosh::process ( float *  input,
float *  output,
unsigned int  numberOfFrames 
)
virtual

Processes the audio.

Always call it in the audio processing callback, regardless if the effect is enabled or not for smooth, audio-artifact free operation. It's never blocking for real-time usage. You can change all properties on any thread, concurrently with process().

Returns
If process() returns with true, the contents of output are replaced with the audio output. If process() returns with false, the contents of output are not changed.
Parameters
inputPointer to floating point numbers. 32-bit interleaved stereo input. The output will be mixed to this. Can be NULL.
outputPointer to floating point numbers. 32-bit interleaved stereo input. Can point to the same location with output (in-place processing).
numberOfFramesNumber of frames to process. Recommendation for best performance: multiply of 4, minimum 64.

Implements Superpowered::FX.

Member Data Documentation

◆ enabled

bool Superpowered::FX::enabled = false
inherited

Turns the effect on/off. The actual switch will happen on the next process() call for smooth, audio-artifact free operation.

◆ frequency

float Superpowered::Whoosh::frequency

Limited to >= 20 and <= 20000.

◆ internals

whooshInternals* Superpowered::Whoosh::internals
private

◆ samplerate

unsigned int Superpowered::FX::samplerate = 0
inherited

Sample rate in Hz.

◆ wet

float Superpowered::Whoosh::wet

Limited to >= 0 and <= 1.


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