spBase
|
Data Structures | |
class | spPlugin |
A class to handle plugin-based processing. More... | |
Typedefs | |
typedef int | spPluginError |
Enumerations | |
enum | spPluginCallbackReason { } |
enum | spPluginState { SP_PLUGIN_STATE_ERROR = -1 , SP_PLUGIN_STATE_STOP = 0 , SP_PLUGIN_STATE_START = 1 , SP_PLUGIN_STATE_PAUSE } |
enum | spPluginDeviceType { SP_PLUGIN_DEVICE_UNKNOWN = -1 , SP_PLUGIN_DEVICE_FILE = 0 , SP_PLUGIN_DEVICE_AUDIO = 1 , SP_PLUGIN_DEVICE_CD = 2 , SP_PLUGIN_DEVICE_MIXER = 3 , SP_PLUGIN_DEVICE_OTHERS = 4 } |
Functions | |
const char * | spGetPluginSearchPath (void) |
void | spSetPluginSearchPath (const char *pathlist) |
spBool | spAppendPluginSearchPath (const char *pathlist) |
spBool | spPrependPluginSearchPath (const char *pathlist) |
spBool | spIsPluginFile (const char *filename) |
char * | xspSearchPluginFile (int index) |
#define SP_PLUGIN_CHECK_VERSION | ( | version, | |
revision, | |||
update ) |
Checks if the version of the spPlugin header files is the same as or newer than the specified version.
[in] | version | The version number. |
[in] | revision | The revision number. |
[in] | update | The update number. |
#define SP_PLUGIN_SUPPORTED_VERSION_ID /*SP_PLUGIN_VERSION_ID*/1003 |
The version ID supported by these header files.
#define SP_PLUGIN_PRIORITY_HIGHEST 0 |
Highest plugin priority.
#define SP_PLUGIN_PRIORITY_HIGHER 1 |
Plugin priority higher than middle.
#define SP_PLUGIN_PRIORITY_MIDDLE 2 |
Middle plugin priority.
#define SP_PLUGIN_PRIORITY_LOWER 3 |
Plugin priority lower than middle.
#define SP_PLUGIN_PRIORITY_LOWEST 4 |
Lowest plugin priority.
#define SP_PLUGIN_PRIORITY_NULL 5 |
Plugin priority is not defined.
#define SP_PLUGIN_ERROR_SUCCESS SP_TRUE |
Success.
#define SP_PLUGIN_ERROR_FAILURE SP_FALSE |
Failure.
#define SP_PLUGIN_ERROR_NO_ERROR SP_TRUE |
No error.
#define SP_PLUGIN_ERROR_WRONG_PLUGIN (-1) |
Wrong plugin.
#define SP_PLUGIN_ERROR_OPEN (-2) |
Error in opening.
#define SP_PLUGIN_ERROR_READ (-3) |
Error in reading.
#define SP_PLUGIN_ERROR_WRITE (-4) |
Error in writing.
#define SP_PLUGIN_ERROR_LOAD (-5) |
Error in loading.
#define SP_PLUGIN_ERROR_SUITABLE_NOT_FOUND (-6) |
No suitable plugin is found.
#define SP_PLUGIN_ERROR_MULTIPLE_INSTANCE (-7) |
Doesn't allow multiple instanciations.
#define SP_PLUGIN_ERROR_INSTANTIATE (-8) |
Error in instantiating.
#define SP_PLUGIN_ERROR_BOGUS_FILE (-10) |
The file is broken.
#define SP_PLUGIN_ERROR_FILE_TYPE (-11) |
Doesn't accept the file type.
#define SP_PLUGIN_ERROR_SAMP_RATE (-12) |
Doesn't accept the sampling rate.
#define SP_PLUGIN_ERROR_SAMP_BIT (-13) |
Doesn't accept the bits/sample.
#define SP_PLUGIN_ERROR_NUM_CHANNEL (-14) |
Doesn't accept the number of channels.
#define SP_PLUGIN_ERROR_OTHER_INFO (-15) |
Error caused by other information.
#define SP_PLUGIN_ERROR_TOTAL_LENGTH_REQUIRED (-16) |
The total length of the file must be specified.
#define SP_PLUGIN_ERROR_UNKNOWN_DEVICE (-20) |
Doesn't recognize the device.
#define SP_PLUGIN_ERROR_USER (-256) |
User defined errors can be defined from this number.
#define SP_PLUGIN_CAPS_THREAD_SAFE (1<<1) |
The plugin is thread-safe. The thread-safe plugin must be run with multiple insntances.
#define SP_PLUGIN_CAPS_NEED_LOCK (1<<2) |
The plugin needs locking.
#define SP_PLUGIN_CAPS_MEMORY_SAFE (1<<3) |
The plugin doesn't execute memory related functions in the read/write function.
#define SP_PLUGIN_CAPS_KEEP_IN_MEMORY (1<<4) |
The plugin doesn't need big memory.
#define SP_PLUGIN_CAPS_CUSTOM_OPTION_DIALOG (1<<5) |
The plugin displays the option dialog specialized for the plugin. If this caps is turned on, A call of free_options with options=NULL must display the option dialog.
#define SP_PLUGIN_CAPS_THREAD_BY_THREAD_SAFE (1<<6) |
The plugin is not true thread-safe, but thread-safe in a thread-by-thread basis.
typedef int spPluginError |
Definition of spPluginError.
enum spPluginState |
enum spPluginDeviceType |
|
extern |
Gets the current search path of plugins.
|
extern |
Sets the directories to search plugins.
[in] | pathlist | The null-terminated path of the directories. This list overrides the current list. Multiple directories can be specified by using the separator of ‘;’ on Windows and Mac or ‘:’ on others. Specifiying NULL will initialize the current list. |
|
extern |
Appends the directories to the tail of the current search path of plugins.
[in] | pathlist | The null-terminated path of the directories. This list will be appended to the tail of the current list. Multiple directories can be specified by using the separator of ‘;’ on Windows and Mac or ‘:’ on others. Specifiying NULL does not change the current list. |
|
extern |
Prepends the directories to the head of the current search path of plugins.
[in] | pathlist | The null-terminated path of the directories. This list will be prepended to the head of the current list. Multiple directories can be specified by using the separator of ‘;’ on Windows and Mac or ‘:’ on others. Specifiying NULL does not change the current list. |
|
extern |
Checks whether the file is a plugin. This function checks that only by using the suffix of the file name, i.e., doesn't load the plugin.
[in] | filename | The null-terminated path of the file. filename is not a body of the name but a actual path as opposed to spLoadPlugin() . |
SP_TRUE | Success |
SP_FALSE | Failure |
|
extern |
Searches the index-th
plugin and Gets the file name of the plugin. This function targets only the files that spIsPluginFile() returns SP_TRUE.
[in] | index | The index for a plugin. |