4#ifndef __SPOUTPUTPLUGIN_H
5#define __SPOUTPUTPLUGIN_H
35#define SP_PLUGIN_OUTPUT "output 1.3"
38#define SP_PLUGIN_CAPS_REPLACE_SONG_INFO (1<<12)
40#define SP_PLUGIN_CAPS_NO_FLOAT_CONVERSION (1<<13)
42#define SP_PLUGIN_CAPS_LIVE_WRITE (1<<14)
45#define SP_PLUGIN_INFO_SONG_INFO_MASK "song_info_mask"
46#define SP_PLUGIN_INFO_BIT_RATE "bit_rate"
47#define SP_PLUGIN_INFO_HEADER_LENGTH "header_length"
48#define SP_PLUGIN_INFO_MPEG_DECODE_OPTION "mpeg_decode_option"
49#define SP_PLUGIN_INFO_NUM_ORDER "num_order"
50#define SP_PLUGIN_INFO_MAX_CHANNEL "max_channel"
52#define SP_PLUGIN_INFO_NUM_BUFFER "num_buffer"
53#define SP_PLUGIN_INFO_BLOCKING_MODE "blocking_mode"
55#define SP_PLUGIN_INFO_DIALOG_RECT "dialog_rect"
56#define SP_PLUGIN_INFO_DIALOG_CREATE "dialog_create"
57#define SP_PLUGIN_INFO_DIALOG_END "dialog_end"
58#define SP_PLUGIN_INFO_DIALOG_DESTROY "dialog_destroy"
61#define SP_BIT_RATE_ID SP_PLUGIN_INFO_BIT_RATE
62#define SP_HEADER_LENGTH_ID SP_PLUGIN_INFO_HEADER_LENGTH
63#define SP_MPEG_DECODE_OPTION_ID SP_PLUGIN_INFO_MPEG_DECODE_OPTION
65#define SP_PLUGIN_INFO_CALLBACK_FUNC "device_callback_func"
66#define SP_PLUGIN_INFO_CALLBACK_TYPE "device_callback_type"
67#define SP_PLUGIN_INFO_CALLBACK_DATA "device_callback_data"
68#define SP_PLUGIN_INFO_CALLBACK_HOST_DATA "device_callback_host_data"
71#define SP_PLUGIN_DEVICE_NO_CALLBACK 0
72#define SP_PLUGIN_DEVICE_OUTPUT_POSITION_CALLBACK (1<<0)
73#define SP_PLUGIN_DEVICE_OUTPUT_BUFFER_CALLBACK (2<<0)
76typedef struct _spOutputPluginRec spOutputPluginRec;
89extern int spFindPluginFileTypeIndex(
spPlugin *plugin,
const char *type);
90extern spBool spSetPluginFileTypeIndex(
spPlugin *plugin,
int index);
91extern int spGetPluginFileTypeIndex(
spPlugin *plugin);
92extern const char *spGetPluginFileTypeString(
spPlugin *plugin,
int index);
93extern const char *spGetPluginFileDescString(
spPlugin *plugin,
int index);
94extern const char *spGetPluginFileFilterString(
spPlugin *plugin,
int index);
95extern spBool spSetPluginFileType(
spPlugin *plugin,
const char *type);
96extern char *xspGetPluginFileType(
spPlugin *plugin,
spBool long_flag);
97extern char *xspGetPluginFileDescription(
spPlugin *plugin,
spBool filter_flag);
98extern char *xspGetPluginFileFilter(
spPlugin *plugin);
99extern spBool spSearchPluginFileType(
int index, spPluginType plugin_type,
101 char *file_type,
char *file_desc,
char *file_filter);
102extern spBool spSearchPluginDevice(
int index, spPluginType plugin_type,
106extern spBool spGetPluginSongInfoMask(
spPlugin *plugin,
unsigned long *info_mask);
107extern const char *spGetPluginBestSuffix(
spPlugin *plugin);
108extern spBool spIsSupportedByPlugin(
spPlugin *plugin,
const char *filename);
110extern spBool spGetPluginNumDevice(
spPlugin *plugin,
int *num_device);
111extern const char *spGetPluginDeviceName(
spPlugin *plugin,
int index);
113extern spBool spSetPluginBufferSize(
spPlugin *plugin,
int buffer_size);
114extern spBool spGetPluginBufferSize(
spPlugin *plugin,
int *buffer_size);
115extern spBool spSetPluginVolume(
spPlugin *plugin,
int channel,
int volume);
116extern spBool spGetPluginVolume(
spPlugin *plugin,
int channel,
int *volume);
117extern spBool spSetPluginVolumeStereo(
spPlugin *plugin,
int l_volume,
int r_volume);
118extern spBool spGetPluginVolumeStereo(
spPlugin *plugin,
int *l_volume,
int *r_volume);
120extern spBool spSetPluginSampleBit(
spPlugin *plugin,
int samp_bit);
121extern spBool spGetPluginSampleBit(
spPlugin *plugin,
int *samp_bit);
122extern spBool spGetPluginDataSampleByte(
spPlugin *plugin,
int *samp_byte);
123extern spBool spGetPluginDataSampleBit(
spPlugin *plugin,
int *samp_bit);
124extern spBool spSetPluginChannel(
spPlugin *plugin,
int num_channel);
125extern spBool spGetPluginChannel(
spPlugin *plugin,
int *num_channel);
126extern spBool spSetPluginSampleRate(
spPlugin *plugin,
double samp_rate);
127extern spBool spGetPluginSampleRate(
spPlugin *plugin,
double *samp_rate);
128extern spBool spSetPluginOtherInfo(
spPlugin *plugin,
const char *
id,
void *data);
129extern spBool spGetPluginOtherInfo(
spPlugin *plugin,
const char *
id,
void *data);
134extern spLong spGetPluginCurrentPosition(
spPlugin *plugin);
189 const char *filename,
const char *mode,
int *current_priority);
216 spPluginOpenCallback call_func,
void *call_data,
237 spPluginOpenCallback call_func,
void *call_data,
spPlugin * spOpenFilePluginAuto(const char *plugin_name, const char *filename, const char *mode, spPluginDeviceType device_type, spWaveInfo *wave_info, spSongInfo *song_info, spPluginOpenCallback call_func, void *call_data, spPluginError *error)
long spWritePluginDouble(spPlugin *plugin, double *data, long length)
long spWritePlugin(spPlugin *plugin, void *data, long length)
spPlugin * spOpenFilePluginArgAuto(const char *plugin_name, const char *filename, const char *mode, spPluginDeviceType device_type, spWaveInfo *wave_info, spSongInfo *song_info, int argc, char **argv, spPluginError *error)
spBool spCloseFilePlugin(spPlugin *plugin)
long spWritePluginDoubleWeighted(spPlugin *plugin, double *data, long length, double weight)
char * xspFindSuitablePluginFileWithPriority(spPluginDeviceType device_type, const char *filename, const char *mode, int *current_priority)
spPlugin * spOpenFilePluginArg(const char *plugin_name, const char *filename, const char *mode, spPluginDeviceType device_type, spWaveInfo *wave_info, spSongInfo *song_info, int argc, char **argv, spPluginError *error)
long spWritePluginInByte(spPlugin *plugin, void *data, long data_size)
spPlugin * spOpenFilePlugin(const char *plugin_name, const char *filename, const char *mode, spPluginDeviceType device_type, spWaveInfo *wave_info, spSongInfo *song_info, spPluginOpenCallback call_func, void *call_data, spPluginError *error)
char * xspFindSuitablePluginFile(spPluginDeviceType device_type, const char *filename, const char *mode)
char * xspFindRelatedPluginFile(const char *plugin_name)