28#ifndef ASYNC_AUDIO_DELAY_LINE_INCLUDED
29#define ASYNC_AUDIO_DELAY_LINE_INCLUDED
153 void mute(
bool do_mute,
int time_ms=0);
210 static const int DEFAULT_FADE_TIME = 10;
226 void writeRemainingSamples(
void);
228 inline float currentFadeGain(
void)
235 float gain = fade_gain[fade_pos];
236 fade_pos += fade_dir;
238 if ((fade_dir > 0) && (fade_pos >= fade_len-1))
241 fade_pos = fade_len-1;
243 else if ((fade_dir < 0) && (fade_pos <= 0))
This file contains the base class for an audio sink.
This file contains the base class for an audio source.
This class implements an audio delay line.
AudioDelayLine(int length_ms)
Constuctor.
~AudioDelayLine(void)
Destructor.
void flushSamples(void)
Tell the sink to flush the previously written samples.
void mute(bool do_mute, int time_ms=0)
Mute audio.
void resumeOutput(void)
Resume audio output to the sink.
int writeSamples(const float *samples, int count)
Write samples into the delay line.
void allSamplesFlushed(void)
The registered sink has flushed all samples.
void clear(int time_ms=-1)
Clear samples in the delay line.
void setFadeTime(int time_ms)
Set the fade in/out time when muting and clearing.
The base class for an audio sink.
The base class for an audio source.
Namespace for the asynchronous programming classes.