27#ifndef ASYNC_AUDIO_DECODER_INCLUDED
28#define ASYNC_AUDIO_DECODER_INCLUDED
38#include <sigc++/sigc++.h>
142 virtual const char *
name(
void)
const = 0;
149 virtual void setOption(
const std::string &
name,
const std::string &value) {}
This file contains the base class for an audio source.
Base class for an audio decoder.
virtual const char * name(void) const =0
Get the name of the codec.
virtual void resumeOutput(void)
Resume audio output to the sink.
virtual ~AudioDecoder(void)
Destructor.
static bool isAvailable(const std::string &name)
Check if a specific decoder is available.
AudioDecoder(void)
Default constuctor.
virtual void allSamplesFlushed(void)
The registered sink has flushed all samples.
sigc::signal< void > allEncodedSamplesFlushed
This signal is emitted when all encoded samples have been flushed.
static AudioDecoder * create(const std::string &name)
Create a new decoder of the specified type.
virtual void setOption(const std::string &name, const std::string &value)
Set an option for the decoder.
virtual void printCodecParams(void) const
Print codec parameter settings.
virtual void writeEncodedSamples(void *buf, int size)=0
Write encoded samples into the decoder.
virtual void flushEncodedSamples(void)
Call this function when all encoded samples have been received.
The base class for an audio source.
void sinkFlushSamples(void)
Namespace for the asynchronous programming classes.