diff options
author | Max Kellermann <max@duempel.org> | 2008-09-07 22:41:17 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2008-09-07 22:41:17 +0200 |
commit | bed2a49fe97b8f070ace2dd37909bb06540c66bd (patch) | |
tree | aa5700adc8317362f121fea88596471ca2c7ba48 /src/audioOutput.h | |
parent | dc7c6bd14d0737f4c7c09c315a6806a901cf9976 (diff) | |
download | mpd-bed2a49fe97b8f070ace2dd37909bb06540c66bd.tar.gz mpd-bed2a49fe97b8f070ace2dd37909bb06540c66bd.tar.xz mpd-bed2a49fe97b8f070ace2dd37909bb06540c66bd.zip |
output: added output_api.h
Just like decoder_api.h, output_api.h provides the audio output API
which is used by the plugins.
Diffstat (limited to '')
-rw-r--r-- | src/audioOutput.h | 67 |
1 files changed, 3 insertions, 64 deletions
diff --git a/src/audioOutput.h b/src/audioOutput.h index d706b602e..82767343b 100644 --- a/src/audioOutput.h +++ b/src/audioOutput.h @@ -19,75 +19,14 @@ #ifndef AUDIO_OUTPUT_H #define AUDIO_OUTPUT_H +#include "output_api.h" #include "../config.h" -#include "pcm_utils.h" -#include "mpd_types.h" -#include "audio_format.h" -#include "tag.h" #include "conf.h" -#include "utils.h" #include "os_compat.h" -#define DISABLED_AUDIO_OUTPUT_PLUGIN(plugin) AudioOutputPlugin plugin; - -typedef struct _AudioOutput AudioOutput; - -typedef int (*AudioOutputTestDefaultDeviceFunc) (void); - -typedef int (*AudioOutputInitDriverFunc) (AudioOutput * audioOutput, - ConfigParam * param); - -typedef void (*AudioOutputFinishDriverFunc) (AudioOutput * audioOutput); - -typedef int (*AudioOutputOpenDeviceFunc) (AudioOutput * audioOutput); - -typedef int (*AudioOutputPlayFunc) (AudioOutput * audioOutput, - const char *playChunk, size_t size); - -typedef void (*AudioOutputDropBufferedAudioFunc) (AudioOutput * audioOutput); - -typedef void (*AudioOutputCloseDeviceFunc) (AudioOutput * audioOutput); - -typedef void (*AudioOutputSendMetadataFunc) (AudioOutput * audioOutput, - const struct tag *tag); - -struct _AudioOutput { - int open; - const char *name; - const char *type; - - AudioOutputFinishDriverFunc finishDriverFunc; - AudioOutputOpenDeviceFunc openDeviceFunc; - AudioOutputPlayFunc playFunc; - AudioOutputDropBufferedAudioFunc dropBufferedAudioFunc; - AudioOutputCloseDeviceFunc closeDeviceFunc; - AudioOutputSendMetadataFunc sendMetdataFunc; - - int convertAudioFormat; - struct audio_format inAudioFormat; - struct audio_format outAudioFormat; - struct audio_format reqAudioFormat; - ConvState convState; - char *convBuffer; - size_t convBufferLen; - int sameInAndOutFormats; - - void *data; -}; - -typedef struct _AudioOutputPlugin { - const char *name; - - AudioOutputTestDefaultDeviceFunc testDefaultDeviceFunc; - AudioOutputInitDriverFunc initDriverFunc; - AudioOutputFinishDriverFunc finishDriverFunc; - AudioOutputOpenDeviceFunc openDeviceFunc; - AudioOutputPlayFunc playFunc; - AudioOutputDropBufferedAudioFunc dropBufferedAudioFunc; - AudioOutputCloseDeviceFunc closeDeviceFunc; - AudioOutputSendMetadataFunc sendMetdataFunc; -} AudioOutputPlugin; +struct audio_format; +struct tag; void initAudioOutputPlugins(void); void finishAudioOutputPlugins(void); |