From: <fea...@li...> - 2006-03-15 14:28:34
|
Revision: 66 Author: alex_lerch Date: 2006-03-15 06:24:19 -0800 (Wed, 15 Mar 2006) ViewCVS: http://svn.sourceforge.net/feapi/?rev=66&view=rev Log Message: ----------- - updated documentation txt-files, doxygen config files and some minor changes in in-source documentation - removed automatic CVS log-comments in files Modified Paths: -------------- trunk/FEAPI/build/Win/ExamplePluginFindMax/ExamplePluginFindMax.dsp trunk/FEAPI/doc/docugenAPI.txt trunk/FEAPI/doc/docugenHost.txt trunk/FEAPI/doc/docugenPlug.txt trunk/FEAPI/doc/doxyconfigAPI trunk/FEAPI/doc/doxyconfigHost trunk/FEAPI/doc/doxyconfigPlug trunk/FEAPI/examples/host/Host_C/FEAPIExampleHost_C.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.h trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.h trunk/FEAPI/examples/plugin/FEAPIExamplePluginLoudness/FEAPIExamplePluginLoudness.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginLoudness/FEAPIExamplePluginLoudness.h trunk/FEAPI/examples/plugin/FEAPIExamplePluginSpectral/FEAPIExamplePluginSpectral.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginSpectral/FEAPIExamplePluginSpectral.h trunk/FEAPI/examples/plugin/FEAPIExamplePluginZeroCrossings/FEAPIExamplePluginZeroCrossings.cpp trunk/FEAPI/examples/plugin/FEAPIExamplePluginZeroCrossings/FEAPIExamplePluginZeroCrossings.h trunk/FEAPI/include/FEAPI.h trunk/FEAPI/sdk/host/include/FEAPIHostUtilities.h trunk/FEAPI/sdk/plugin/include/FEAPIEntryPoints.h trunk/FEAPI/sdk/plugin/include/FEAPIPluginBase.h trunk/FEAPI/sdk/plugin/src/FEAPIPluginBase.cpp Modified: trunk/FEAPI/build/Win/ExamplePluginFindMax/ExamplePluginFindMax.dsp =================================================================== --- trunk/FEAPI/build/Win/ExamplePluginFindMax/ExamplePluginFindMax.dsp 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/build/Win/ExamplePluginFindMax/ExamplePluginFindMax.dsp 2006-03-15 14:24:19 UTC (rev 66) @@ -131,10 +131,6 @@ # End Source File # Begin Source File -SOURCE=..\..\..\sdk\plugin\include\FEAPIEntryPoints.h -# End Source File -# Begin Source File - SOURCE=..\..\..\sdk\plugin\include\FEAPIPluginBase.h # End Source File # End Group Modified: trunk/FEAPI/doc/docugenAPI.txt =================================================================== --- trunk/FEAPI/doc/docugenAPI.txt 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/docugenAPI.txt 2006-03-15 14:24:19 UTC (rev 66) @@ -2,7 +2,7 @@ // ///////////////////////////////////////////////////////////////////////////////////// // -// Copyright (c) 2004-2005, Alexander Lerch, zplane.development GbR +// Copyright (c) 2004-2006, Alexander Lerch, zplane.development GbR // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -34,25 +34,6 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author$ -// $Date$ -// -// $Log$ -// Revision 1.2 2005/05/20 17:01:57 alex_lerch -// - updated documentation -// -// Revision 1.1.1.1 2005/03/30 14:54:38 alex_lerch -// first draft version requiring several updates: -// - interface check -// - check of plugin base class -// - implementation of host base class -// - update of outdated documentation -// -// -//////////////////////////////////////////////////////////////////////////////////// /*! \mainpage Feature Extraction API Documentation @@ -86,7 +67,6 @@ <BR><BR> - \section api API Documentation The API declaration and short function descriptions can be found in the file FEAPI.h. Note that the function pointer declarations are used as synonyms for the function names itself. @@ -99,16 +79,16 @@ \subsubsection instance Instance Controlling Before using the Plugin, an instance has to be created. After the Plugin usage, this instance has to be destroyed to free the allocated memory and resources. <UL> - <li> <b>FEAPI_Error_t ::FEAPI_CreatePluginInstance_t (::FEAPI_PluginInstance_t *phInstanceHandle)</b><br> + <li> <b>::FEAPI_Error_t ::FEAPI_CreatePluginInstance_t (::FEAPI_PluginInstance_t *phInstanceHandle)</b><br> Upon the call of this function, a new instance is created. The handle to the new instance is written to the function parameter phInstanceHandle. <BR> The return value is ::FEAPI_kNoError in case of no error. - <li> <b>FEAPI_Error_t ::FEAPI_DestroyPluginInstance_t (::FEAPI_PluginInstance_t *phInstanceHandle)</b><br> + <li> <b>::FEAPI_Error_t ::FEAPI_DestroyPluginInstance_t (::FEAPI_PluginInstance_t *phInstanceHandle)</b><br> The instance pointed to in phInstanceHandle is destroyed with this function call.<BR> The return value is ::FEAPI_kNoError in case of no error. - <li> <b>FEAPI_Error_t ::FEAPI_InitializePlugin_t (::FEAPI_PluginInstance_t hInstanceHandle, float fInputSampleRate, int iNumberOfAudioChannels, int iHostApiMajorVersion, ::FEAPI_UserData_t *pstUserData)</b><br> - This function initializes the plug-in and does the internal memory allocation. fSampleRate gives the sample rate in Hz, while iNumberOfChannels gives the audio channel count. iHostApiMajorVersion contains the major version number of the host's FEAPI implementation and pstUserData is either NULL or contains some special vendor specific data. Note that neither the sample rate nor the number of channels can be modified after the instance creation.<BR> + <li> <b>::FEAPI_Error_t ::FEAPI_InitializePlugin_t (::FEAPI_PluginInstance_t hInstanceHandle, float fInputSampleRate, int iNumberOfAudioChannels, int iHostApiMajorVersion, ::FEAPI_UserData_t *pstUserData)</b><br> + This function initializes the plug-in and does the internal memory allocation. fSampleRate gives the sample rate in Hz, while iNumberOfChannels gives the audio channel count. iHostApiMajorVersion contains the major version number of the host's FEAPI implementation and pstUserData is either NULL or contains some special vendor specific data. Note that neither the sample rate nor the number of channels can be modified after the instance creation. The function has to be called at least once before the first call of ::FEAPI_ProcessPlugin_t and after changing a parameter with property non-realtime.<BR> The return value is ::FEAPI_kNoError in case of no error. </ul> @@ -118,11 +98,11 @@ <LI> <b>int ::FEAPI_GetPluginAPIVersion_t (::FEAPI_VersionInfo_t eAPIMajorMinorOrSubVersion)</b><br> The API version is defined in the format major.minor.sub, each of them (major, minor, and sub) being an integer. This function returns the API version being used for the plugin for one of the three possibilities as specified with eAPIMajorMinorOrSubVersion. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginName_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginName)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginName_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginName)</b><br> Call this function to retrieve the name of the Plugin. hInstanceHandle points to the current instance. The Plugin name is copied to the function parameter pcPluginName. Note the the host has to allocate at least 1024Bytes including the string termination for the string.<BR> The return value is ::FEAPI_kNoError in case of no error. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginVendor_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginVendor)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginVendor_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginVendor)</b><br> Call this function to retrieve the vendor string of the Plugin. hInstanceHandle points to the current instance. The Plugin vendor string is copied to the function parameter pcPluginVendor. Note the the host has to allocate at least 1024Bytes including the string termination for the string.<BR> The return value is ::FEAPI_kNoError in case of no error. @@ -130,18 +110,18 @@ Call this function to retrieve information about the basic capabilities of the Plugin. hInstanceHandle points to the current instance. The requested property is specified in ePluginProperty. For information about possible requests please look at ::FEAPI_PluginProperty_t .<BR> The return value is the requested value in float format. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginId_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginId)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginId_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginId)</b><br> Call this function to retrieve the vendor specific ID of the Plugin. hInstanceHandle points to the current instance. The Plugin ID string is copied to the function parameter pcPluginId. Note the the host has to allocate at least 1024Bytes including the string termination for the string.<BR> The return value is ::FEAPI_kNoError in case of no error. <LI> <b>int ::FEAPI_GetPluginVendorVersion_t (::FEAPI_PluginInstance_t hInstanceHandle, ::FEAPI_VersionInfo_t ePluginMajorMinorOrSubVersion)</b><br> hInstanceHandle points to the current instance. This function can be used exactly the same way as ::FEAPI_GetPluginAPIVersion_t but returns the vendor version of the Plugin instead of its API version. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginDescription)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginDescription)</b><br> Call this function to retrieve a description of what the Plugin actually does. hInstanceHandle points to the current instance. The Plugin description string is copied to the function parameter pcPluginDescription. Note the the host has to allocate at least 4096Bytes excluding the string termination for the string.<BR> The return value is ::FEAPI_kNoError in case of no error. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginCopyright_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginCopyright)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginCopyright_t (::FEAPI_PluginInstance_t hInstanceHandle, char *pcPluginCopyright)</b><br> Call this function to retrieve copyright information about the Plugin. hInstanceHandle points to the current instance. The copyright string is copied to the function parameter pcPluginCopyright. Note the the host has to allocate at least 1024Bytes excluding the string termination for the string.<BR> The return value is ::FEAPI_kNoError in case of no error. </ul> @@ -152,25 +132,25 @@ <LI> <b>int ::FEAPI_GetPluginNumOfInputs_t (::FEAPI_PluginInstance_t hInstanceHandle)</b><br> Call this function to retrieve the number of inputs required by the Plugin. hInstanceHandle points to the current instance. In most cases, the return value will equal the number of audio channels. It can never be smaller than the number of audio channels. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginInputDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iInputIndex, ::FEAPI_SignalDescription_t *pstInputDescription)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginInputDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iInputIndex, ::FEAPI_SignalDescription_t *pstInputDescription)</b><br> Call this function to retrieve a description of a specific input. hInstanceHandle points to the current instance. iInputIndex is the parameter index ranging from 0 for the first parameter to (number of inputs -1). The detailed input description is copied to the function parameter pstInputDescription pointer to a structure of type ::FEAPI_SignalDescription_t. Note the the host has to allocate the memory for the parameter description structure.<BR> The return value is ::FEAPI_kNoError in case of no error. </ul> \subsubsection paramfunc Parameter Control Functions - Parameters can be used to control the Plugin algorithm configuration. For each single parameter, several properties are defined in the ::FEAPI_ParameterDescription_t structure, that contains name, unit, range, description and information if the parameter is quantized. Each parameter has to be in float format. + Parameters can be used to control the Plugin algorithm configuration. For each single parameter, several properties are defined in the ::FEAPI_ParameterDescription_t structure, that contains name, unit, range, description and information if the parameter is quantized. Each parameter has to be in float format. Note the property ::FEAPI_ParameterDescription_t::bIsChangeableInRealTime that - in case of set to non-realtime - requires a call of ::FEAPI_InitializePlugin_t after changing the parameter value. <UL> <LI> <b>int ::FEAPI_GetPluginNumOfParameters_t (::FEAPI_PluginInstance_t hInstanceHandle)</b><br> Call this function to retrieve the number of parameters provided by the Plugin. hInstanceHandle points to the current instance. If no parameter for configuration is provided, the function returns 0. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginParameterDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iParameterIndex, ::FEAPI_ParameterDescription_t *pstParameterDescription)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginParameterDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iParameterIndex, ::FEAPI_ParameterDescription_t *pstParameterDescription)</b><br> Call this function to retrieve a description of a special parameter. hInstanceHandle points to the current instance. iParameterIndex is the parameter index ranging from 0 for the first parameter to (number of parameters -1). The detailed parameter description is copied to the function parameter pstParameterDescription pointer to a structure of type ::FEAPI_ParameterDescription_t. Note the the host has to allocate the memory for the parameter description structure.<BR> The return value is ::FEAPI_kNoError in case of no error. <LI> <b>float ::FEAPI_GetPluginParameter_t (::FEAPI_PluginInstance_t hInstanceHandle, int iParameterIndex)</b><br> Call this function to retrieve the current value of a special parameter with index iParameterIndex. hInstanceHandle points to the current instance. - <LI> <b>FEAPI_Error_t ::FEAPI_SetPluginParameter_t (::FEAPI_PluginInstance_t hInstanceHandle, int iParameterIndex, float fValue)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_SetPluginParameter_t (::FEAPI_PluginInstance_t hInstanceHandle, int iParameterIndex, float fValue)</b><br> Call this function to set the value of a special parameter with index iParameterIndex to the value fValue. hInstanceHandle points to the current instance. <BR> The return value is ::FEAPI_kNoError in case of no error. @@ -178,28 +158,29 @@ \subsubsection processfunc Process Functions <UL> - <LI> <b>FEAPI_Error_t ::FEAPI_ProcessPlugin_t (::FEAPI_PluginInstance_t hInstanceHandle, const FEAPI_Signal_t **ppfInputBuffer, const FEAPI_TimeStamp_t *ptFEAPI_TimeStamp,int iNumberOfFrames)</b><br> - The process function does the actual feature resp. result calculation. It has to be called with subsequent blocks of audio input data. hInstanceHandle points to the current instance, ppfInputBuffer points to the current block of audio data as two dimensional array in the format [channels][samples]. A time stamp in seconds marking the beginning of the data may be given, to make synchronisation more easy. The number of frames is given in iNumberOfFrames.<BR> + <LI> <b>::FEAPI_Error_t ::FEAPI_ProcessPlugin_t (::FEAPI_PluginInstance_t hInstanceHandle, const FEAPI_Signal_t **ppfInputBuffer, const FEAPI_TimeStamp_t *ptFEAPI_TimeStamp,int iNumberOfFrames)</b><br> + The process function does the actual feature resp. result calculation. It has to be called with subsequent blocks of audio input data. hInstanceHandle points to the current instance, ppfInputBuffer points to the current block of audio data as two dimensional array in the format [channels][samples]. A time stamp in seconds marking the beginning of the data may be given, to make synchronisation more easy. The number of frames is given in iNumberOfFrames and has to be compliant to the minimum and maximum frame size boundaries given in ::FEAPI_PluginProperty_t.<BR> The return value is ::FEAPI_kNoError in case of no error. - <LI> <b>FEAPI_Error_t ::FEAPI_ProcessPluginDone_t (::FEAPI_PluginInstance_t hInstanceHandle)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_ProcessPluginDone_t (::FEAPI_PluginInstance_t hInstanceHandle)</b><br> Call this function after the last call of ::FEAPI_ProcessPlugin_t, i.e. when no more new audio data is available. hInstanceHandle points to the current instance.<BR> The return value is ::FEAPI_kNoError in case of no error. </ul> \subsubsection resultfunc Result Handling Functions - The Feature Extraction API allows the calculation of as many results as needed. Each result may consist of an one-dimensional array of floating point data. For each single result, several properties are defined in the ::FEAPI_SignalDescription_t structure, that contains name, unit, range, description, information about the result's quantization and output sample rate if it is constant. + The Feature Extraction API allows the calculation of one or more features at a time. For each single result, several properties are defined in the ::FEAPI_SignalDescription_t structure, that contains name, unit, range, description, information about the result's quantization and output sample rate if it is constant.<br> + A single result can be a single value, or can be an array of values (like e.g. a magnitude spectrum). Furthermore, depending on the size of the process input buffer, it can be that there are several succeeding results with different time stamps at one time. <UL> <LI> <b>int ::FEAPI_GetPluginNumOfResults_t (::FEAPI_PluginInstance_t hInstanceHandle)</b><br> - Call this function to retrieve the number of results (features) that the Plugin is able to calculate. hInstanceHandle points to the current instance. If no result computed (an unlikely case), the function returns 0. + Call this function to retrieve the number of results (features) that the Plugin is able to extract. hInstanceHandle points to the current instance. Even if a result is multidimensional, its count will be one. If no result is computed (an unlikely case), the function returns 0. - <LI> <b>FEAPI_Error_t ::FEAPI_GetPluginResultDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iResultIndex, ::FEAPI_SignalDescription_t *pstResultDescription)</b><br> + <LI> <b>::FEAPI_Error_t ::FEAPI_GetPluginResultDescription_t (::FEAPI_PluginInstance_t hInstanceHandle, int iResultIndex, ::FEAPI_SignalDescription_t *pstResultDescription)</b><br> Call this function to retrieve a description of a special result (feature). hInstanceHandle points to the current instance. iResultIndex is the parameter index ranging from 0 for the first parameter to (number of results -1). The detailed result description is copied to the function parameter pstResultDescription pointer to a structure of type ::FEAPI_SignalDescription_t. Note the the host has to allocate the memory for the result description structure.<BR> The return value is ::FEAPI_kNoError in case of no error. <LI> <b>int ::FEAPI_GetPluginSizeOfResult_t (::FEAPI_PluginInstance_t hInstanceHandle, int iResultIndex)</b><br> - Call this function before each call of ::FEAPI_GetPluginResult_t to retrieve the size of the result with index iResultIndex in float values. + Call this function before each call of ::FEAPI_GetPluginResult_t to retrieve the size of the result with index iResultIndex in float values. Note that this function returns always the size of one result, i.e. if the result is a single value, it will always return 1. For an N-dimensional result, it will return N. This function has to be called in combination with ::FEAPI_GetPluginResults_t until it returns 0. <LI> <b>int ::FEAPI_GetPluginResult_t (::FEAPI_PluginInstance_t hInstanceHandle, int iResultIndex, ::FEAPI_Signal_t *pfResult, ::FEAPI_TimeStamp_t *ptFEAPI_TimeStamp)</b><br> Call this function to retrieve result with index iResultIndex after one process call. The result is copied to the buffer pointed to by pfResult. Note that due to the push interface, it may be possible that the plugin has several succeeding results for the same result index. Therefore, call this function with the same iResultIndex until ::FEAPI_GetPluginSizeOfResult_t returns 0. hInstanceHandle points to the current instance. The Plugin name is copied to the function parameter pcPluginName. Note the the host has to allocate this buffer acc. to the previously requested size of the result. @@ -222,6 +203,26 @@ * <br><br> * <br><br> * + * +\section platforms Platform Specific Definitions +The Feature Extraction plugin API is developed to be platform independent. The specific implementation and usage of plugin and host may have to be platform specific to some extent. Note that in its current state FEAPI, was only implemented and tested on Win32 and MacOSX; the following recommendations refer to these platforms. + +\subsection dir System Plugin Directories +The following directories should be the default directories for FEAPI plugins: +<ul> + <li> Win32+Win64: $ProgramFiles/FEAPI + <li> MacOsX: /Library/Audio/Plug-Ins/FEAPI +</ul> +This is however only the default location, and host implementations should allow the user to specify one or more additional directories to search for plugins. + +\subsection ext Plugin Extensions +The host has to test possible plugins for feapi compliance by checking the libaray API. Therefore, the used file extension is not of much importance. It is recommended, that the file extension used are: +<ul> + <li> Win32+Win64: .dll + <li> MacOsX: .feapi +</ul> + + * \section license License The Feature Extraction API is released under a BSD-style license. Therefore, static linking of the API without publishing other sources of the project is allowed and the code may be used in open source as well as in commercial products with the small restrictions mentioned in the license itself (see FEAPI.h).<BR> Please keep the authors or contributors informed about any extensions or fixes of the source files.<br> @@ -282,6 +283,7 @@ * * * \section contact Contact - * alexander lerch (lerch <at> zplane.de)<br> + * web: http://feapi.sf.net<br> + * feapi mailing list: fea...@li...<br> * */ Modified: trunk/FEAPI/doc/docugenHost.txt =================================================================== --- trunk/FEAPI/doc/docugenHost.txt 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/docugenHost.txt 2006-03-15 14:24:19 UTC (rev 66) @@ -2,7 +2,7 @@ // ///////////////////////////////////////////////////////////////////////////////////// // -// Copyright (c) 2004-2005, Alexander Lerch, zplane.development GbR +// Copyright (c) 2004-2006, Alexander Lerch, zplane.development GbR // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -34,61 +34,33 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author$ -// $Date$ -// -// $Log$ -// Revision 1.3 2005/05/23 13:53:33 koentanghe -// corrected <bR< tag into <br> -// -// Revision 1.2 2005/05/20 17:02:09 alex_lerch -// - updated documentation -// -// Revision 1.1.1.1 2005/03/30 14:54:38 alex_lerch -// first draft version requiring several updates: -// - interface check -// - check of plugin base class -// - implementation of host base class -// - update of outdated documentation -// -// -//////////////////////////////////////////////////////////////////////////////////// /*! \mainpage Feature Extraction Host Documentation \section intro Introduction - This documentation is a short introduction about how a win32 host for the Feature Extraction API can be implemented. For information about the Feature Extraction Plugin API itself, please refer to the API documentation itself.<br> - Please note that the implementation shows only how a fast implementation can be done, there might be many alternative ways to implement such an host. + This documentation is a short introduction about how a win32 host for the Feature Extraction API, using directly the C-API and no API interface, can be implemented. For information about the Feature Extraction Plugin API itself, please refer to the API documentation.<br> + Please note that the implementation shows only how a fast implementation can be done, there might be many alternative and cleaner ways to implement such an host. <BR><BR> <BR><BR> - - - - \section prog Win32 Host Implementation + + \section prog Win32 Host Implementation using the C interface \dontinclude FEAPIExampleHost_C.cpp - The following code snippets should give you an example about the calling conventions etc. of such a host. The complete code can be found in the example file FEAPITestCLMain.cpp. Note that the application uses the library libSndFile for all operations on audio files.<br> - First, the working directory is searched for Plugin DLL with the local function ::FindPlugIns: + The following code snippets should give you an example about the calling conventions etc. of such a host. The complete code can be found in the example file FEAPIExampleHost_C.cpp. Note that the application uses the library libSndFile for all operations on audio files, which is not included in the SDK itself and has to be downloaded separately (see http://www.mega-nerd.com/libsndfile/) for details. <br> + First, the working directory is searched for Plugin DLL with the local function ::FindPlugIns, as declared in FEAPIHostUtilities.h (to parse the working directory is a simplified method; note that the specific directories to be parsed by a host should comply to the platform specific recommendation in the API documentation): \skipline find \until FindPlugins - For the Plugin to be selected for processing, the DLL has to be loaded: + For the Plugin to be selected for processing, the library can be loaded with the function ::LoadPluginModule and the API function pointers can be retrieved with the function ::GetFunctionPointers, both declared in FEAPIHostUtilities.h: - \skipline load - \until LoadLibrary + \skipline hLibraryHandle + \until GetFunctionPointers - After that, the API function pointers can be retrieved from the DLL. Here, this is done with the local function GetFunctionPointers which checks if the DLL API conforms to the required API and writes all function pointers to a pre-defined structure: + Function ::GetFunctionPointers verifies the API compliance and writes the function pointers to ::stPluginFunctions.<br> + Now we are ready to create a new instance of the Plugin: - \skipline get - \until } - - The first thing to do is to create a new instance of the Plugin: - \skipline create \until Failed @@ -111,35 +83,36 @@ Then, the actual processing can take place. Since in this host implementation the input buffer size does not matter, we ask the plugin about its preferred buffer size. Therefore, we call - \skipline FEAPI_kOptFrameSize + \skipline iNumOfFramesNeeded + \until FEAPI_kOptFrameSize - In the next step, the process function can be called the the requested input audio data: + In the next step, the process function can be called with the requested amount of input audio data: \skipline processing \until iNumOfFramesNeeded - Note that time stamp handling is not yet included. <br> - Now, the current results can be retrieved. First, the size of the results is queried to assure that the host buffers have sufficient size. Then all results are retrieved and printed to an output text file if requested: + Now, the current results can be retrieved, if available. First, the size of the results is queried to assure that the host buffers have sufficient size to hold the result values. Then, all results are retrieved and printed to an output text file if requested: \skipline get \until pFOutputFile \until } - After all audio data has been subsequently processed and no more audio data is available, the Plugins should be noticed about this circumstance: + After all audio data has been subsequently processed and no more audio data is available, the Plugin should be noticed about this circumstance: \skipline notice \until ProcessDone - Upon this, the last results can be retrieved in the same way as described above. Finally the Plugin instance can be destroyed and the DLL freed: + After this, the last results can be retrieved (if available) in the same way as described above. Finally the Plugin instance can be destroyed and the Library unloaded: \skipline instance - \until FreeLibrary + \until UnloadPluginModule * <br><br> * <br><br> * * \section contact Contact - * alexander lerch (lerch <at> zplane.de)<br> + * web: http://feapi.sf.net<br> + * feapi mailing list: fea...@li...<br> * */ Modified: trunk/FEAPI/doc/docugenPlug.txt =================================================================== --- trunk/FEAPI/doc/docugenPlug.txt 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/docugenPlug.txt 2006-03-15 14:24:19 UTC (rev 66) @@ -1,8 +1,7 @@ ///////////////////////////////////////////////////////////////////////////////////// -// ///////////////////////////////////////////////////////////////////////////////////// // -// Copyright (c) 2004-2005, Alexander Lerch, zplane.development GbR +// Copyright (c) 2004-2006, Alexander Lerch, zplane.development GbR // All rights reserved. // // Redistribution and use in source and binary forms, with or without @@ -34,28 +33,6 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author$ -// $Date$ -// -// $Log$ -// Revision 1.3 2005/07/11 16:53:38 alex_lerch -// - fixed two typos -// -// Revision 1.2 2005/05/20 17:02:09 alex_lerch -// - updated documentation -// -// Revision 1.1.1.1 2005/03/30 14:54:38 alex_lerch -// first draft version requiring several updates: -// - interface check -// - check of plugin base class -// - implementation of host base class -// - update of outdated documentation -// -// -//////////////////////////////////////////////////////////////////////////////////// /*! \mainpage Feature Extraction Plugin Documentation @@ -63,38 +40,73 @@ \section intro Introduction This is a short tutorial on how to implement a Plugin conforming to the feature extraction Plugin API.<bR> - Although the Plugin interface is in the language C, the Plugin internals are in C++ to guarantee API conformance without too much work. + Although the Plugin interface is in the language C, the Plugin SDK internals are in C++ to ensure API conformance with minimal implementation effort. <BR><BR> <BR><BR> \section tut Step-by-Step tutorial - For the implementation, you need the following files: + For the implementation, you need the following SDK files: <ul> <LI> FEAPI.h: the Plugin API interface itself (do never edit!) - <LI> FeatureExtractBase.h: the Plugin base class interface (do never edit!) - <LI> FeatureExtractBase.cpp: prototype implementation of "internal" API functions (do never edit!) - <LI> FEAPI.cpp: the implementation of the API functions - <LI> only under windows: FEAPI.def to define the dll exports + <LI> FEAPIPluginBase.h: the Plugin base class interface (do never edit!) + <LI> FEAPIPluginBase.cpp: prototype implementation of "internal" API functions (do never edit!) + <LI> FEAPIEntryPoints.h: the definition of the API functions (do never edit!) </ul> - To make each step more transparent, please refer to the provided example Plugin source code (FindAbsoluteMax).<BR><BR> + To make each step more transparent, please refer to the source code of the example plugin (e.g. FindAbsoluteMax).<BR><BR> The following steps are necessary: <UL> - <LI> Create a new project for a shared library with the above files. - <LI> add a new class the is inherited from the class ::CFeatureExtractBase defined in FeatureExtractBase.h - <LI> in your class header, be sure to add the define _THE_PLUGIN_CLASS to be the name of your class (example: #define _THE_PLUGIN_CLASS CFindAbsoluteMax - <LI> include your class header file in FEAPI.cpp. Be sure not to edit the rest of this file. - <LI> under windows, change the contents of the field LIBRARY in the FEAPI.def to your selected output DLL name (example: LIBRARY "FindAbsoluteMax") - <LI> in your class implementation, implement at least all pure virtual functions from the base class + <LI> add the above files to your project to build a shared library. + <LI> add a new class that is inherited from the class ::CFeatureExtractBase defined in FEAPIPluginBase.h; let's assume your class is named CMyPlug, its interface is in MyPlug.h, its implementation is in MyPlug.cpp. + <LI> do not forget to add the following lines to the beginning MyPlug.cpp: + \code + #include "FEAPI.h" + #include "MyPlug.h" + #include "FEAPIEntryPoints.h" + \endcode + + <LI> and at the end of file MyPlug.cpp, add the following code + \code + /////////////////////////////////////// + // entry points + #ifdef __cplusplus + extern "C" { + #endif + + FEAPI_ENTRY_POINTS(CMyPlug) // insert your class name here + + #ifdef __cplusplus + } + #endif + /////////////////////////////////////// +\endcode + <LI> in the interface and implementation of CMyPlug, declare and implement at least all pure virtual functions from the base class </UL> - After these steps, your Plugin compiles, but does nothing than just return the default values on all function calls. To change this behaviour, just the functions inherited from CFEAPIBase have to be implemented in your class. - - * <br><br> - * <br><br> - \todo add section about methods that have to be overridden, that can be optionally overridden and that must not be overridden + After these steps, your plugin compiles, but does nothing than just return the default values on all method calls. To change this behaviour, just the methods inherited from CFEAPIBase have to be implemented in your class. * + * + * \section virtual Pure Virtual Base Class Methods + * To get a working plugin, at least the following methods have to be implemented (for documentation, please refer to the API documentation: + * <ul> + * <li> ::CFeatureExtractBase::GetPluginProperty (::FEAPI_PluginProperty_t ePluginProperty) + * <li> ::CFeatureExtractBase::ProcessPlugin (const ::FEAPI_Signal_t **ppfInputBuffer, const ::FEAPI_TimeStamp_t *ptFEAPI_TimeStamp, int iNumberOfFrames) + * <li> ::CFeatureExtractBase::GetPluginSizeOfResult (int iResultIndex) + * <li> ::CFeatureExtractBase::GetPluginResult (int iResultIndex, float *pfResult, ::FEAPI_TimeStamp_t *ptFEAPI_TimeStamp) + * </ul> + * <br> + * + * \section virtual Other Virtual Class Methods + * For implementing a real-world plugin, you may however require to override also the following methods: + * <ul> + * <li> ::CFeatureExtractBase::GetPluginInputDescription (int iInputIndex, ::FEAPI_SignalDescription_t *pstInputDescription) + * <li> ::CFeatureExtractBase::GetPluginResultDescription (int iResultIndex, ::FEAPI_SignalDescription_t *pstResultDescription) + * <li> ::CFeatureExtractBase::GetPluginParameterDescription (int iParameterIndex, ::FEAPI_ParameterDescription_t *pstParameterDescription) + * <li> ::CFeatureExtractBase::SetPluginParameter (int iParameterIndex, float fValue) + * <li> ::CFeatureExtractBase::GetPluginParameter (int iParameterIndex) + * * \section contact Contact - * alexander lerch (lerch <at> zplane.de)<br> + * web: http://feapi.sf.net<br> + * feapi mailing list: fea...@li...<br> * */ Modified: trunk/FEAPI/doc/doxyconfigAPI =================================================================== --- trunk/FEAPI/doc/doxyconfigAPI 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/doxyconfigAPI 2006-03-15 14:24:19 UTC (rev 66) @@ -1,11 +1,11 @@ -# Doxyfile 1.3.9.1 +# Doxyfile 1.4.5 #--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- PROJECT_NAME = "Feature Extraction API documentation" PROJECT_NUMBER = -OUTPUT_DIRECTORY = ../doc +OUTPUT_DIRECTORY = CREATE_SUBDIRS = NO OUTPUT_LANGUAGE = English USE_WINDOWS_ENCODING = YES @@ -32,11 +32,13 @@ MULTILINE_CPP_IS_BRIEF = YES DETAILS_AT_TOP = YES INHERIT_DOCS = YES -DISTRIBUTE_GROUP_DOC = NO +SEPARATE_MEMBER_PAGES = NO TAB_SIZE = 4 ALIASES = OPTIMIZE_OUTPUT_FOR_C = YES OPTIMIZE_OUTPUT_JAVA = NO +BUILTIN_STL_SUPPORT = NO +DISTRIBUTE_GROUP_DOC = NO SUBGROUPING = YES #--------------------------------------------------------------------------- # Build related configuration options @@ -66,6 +68,7 @@ MAX_INITIALIZER_LINES = 30 SHOW_USED_FILES = YES SHOW_DIRECTORIES = YES +FILE_VERSION_FILTER = #--------------------------------------------------------------------------- # configuration options related to warning and progress messages #--------------------------------------------------------------------------- @@ -73,13 +76,14 @@ WARNINGS = YES WARN_IF_UNDOCUMENTED = NO WARN_IF_DOC_ERROR = YES +WARN_NO_PARAMDOC = NO WARN_FORMAT = "$file:$line: $text" WARN_LOGFILE = warn.log #--------------------------------------------------------------------------- # configuration options related to the input files #--------------------------------------------------------------------------- -INPUT = ../incl/FEAPI.h \ - ../doc/docugenAPI.txt +INPUT = ../include/FEAPI.h \ + docugenAPI.txt FILE_PATTERNS = *.h \ *.hpp \ *.txt \ @@ -103,6 +107,7 @@ STRIP_CODE_COMMENTS = YES REFERENCED_BY_RELATION = YES REFERENCES_RELATION = YES +USE_HTAGS = NO VERBATIM_HEADERS = YES #--------------------------------------------------------------------------- # configuration options related to the alphabetical class index @@ -208,18 +213,22 @@ HAVE_DOT = YES CLASS_GRAPH = YES COLLABORATION_GRAPH = YES +GROUP_GRAPHS = YES UML_LOOK = NO TEMPLATE_RELATIONS = YES INCLUDE_GRAPH = YES INCLUDED_BY_GRAPH = YES CALL_GRAPH = YES GRAPHICAL_HIERARCHY = YES +DIRECTORY_GRAPH = YES DOT_IMAGE_FORMAT = png -DOT_PATH = +DOT_PATH = C:/Programme/Grafik/GraphViz/Graphviz/bin DOTFILE_DIRS = MAX_DOT_GRAPH_WIDTH = 1024 MAX_DOT_GRAPH_HEIGHT = 1024 MAX_DOT_GRAPH_DEPTH = 1000 +DOT_TRANSPARENT = NO +DOT_MULTI_TARGETS = NO GENERATE_LEGEND = YES DOT_CLEANUP = YES #--------------------------------------------------------------------------- Modified: trunk/FEAPI/doc/doxyconfigHost =================================================================== --- trunk/FEAPI/doc/doxyconfigHost 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/doxyconfigHost 2006-03-15 14:24:19 UTC (rev 66) @@ -1,11 +1,11 @@ -# Doxyfile 1.3.9.1 +# Doxyfile 1.4.5 #--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- PROJECT_NAME = "Feature Extraction Host documentation" PROJECT_NUMBER = -OUTPUT_DIRECTORY = ../doc +OUTPUT_DIRECTORY = CREATE_SUBDIRS = NO OUTPUT_LANGUAGE = English USE_WINDOWS_ENCODING = YES @@ -32,11 +32,13 @@ MULTILINE_CPP_IS_BRIEF = YES DETAILS_AT_TOP = YES INHERIT_DOCS = YES -DISTRIBUTE_GROUP_DOC = NO +SEPARATE_MEMBER_PAGES = NO TAB_SIZE = 4 ALIASES = OPTIMIZE_OUTPUT_FOR_C = YES OPTIMIZE_OUTPUT_JAVA = NO +BUILTIN_STL_SUPPORT = NO +DISTRIBUTE_GROUP_DOC = NO SUBGROUPING = YES #--------------------------------------------------------------------------- # Build related configuration options @@ -66,6 +68,7 @@ MAX_INITIALIZER_LINES = 30 SHOW_USED_FILES = YES SHOW_DIRECTORIES = YES +FILE_VERSION_FILTER = #--------------------------------------------------------------------------- # configuration options related to warning and progress messages #--------------------------------------------------------------------------- @@ -73,14 +76,17 @@ WARNINGS = YES WARN_IF_UNDOCUMENTED = NO WARN_IF_DOC_ERROR = YES +WARN_NO_PARAMDOC = NO WARN_FORMAT = "$file:$line: $text" WARN_LOGFILE = warn.log #--------------------------------------------------------------------------- # configuration options related to the input files #--------------------------------------------------------------------------- -INPUT = ../doc/docugenHost.txt \ - ../incl/FEAPI.h \ - ../src/Host_C/FEAPIExampleHost_C.cpp +INPUT = docugenHost.txt \ + ../include/FEAPI.h \ + ../examples/host/Host_C/FEAPIExampleHost_C.cpp \ + ../sdk/host/include/FEAPIHostUtilities.h \ + ../sdk/host/include/FEAPIHostDeclarations.h FILE_PATTERNS = *.h \ *.hpp \ *.txt \ @@ -89,7 +95,7 @@ EXCLUDE = EXCLUDE_SYMLINKS = NO EXCLUDE_PATTERNS = -EXAMPLE_PATH = ../src/Host_C +EXAMPLE_PATH = ../examples/host/Host_C EXAMPLE_PATTERNS = *.cpp EXAMPLE_RECURSIVE = NO IMAGE_PATH = @@ -104,6 +110,7 @@ STRIP_CODE_COMMENTS = YES REFERENCED_BY_RELATION = YES REFERENCES_RELATION = YES +USE_HTAGS = NO VERBATIM_HEADERS = YES #--------------------------------------------------------------------------- # configuration options related to the alphabetical class index @@ -209,18 +216,22 @@ HAVE_DOT = YES CLASS_GRAPH = YES COLLABORATION_GRAPH = YES +GROUP_GRAPHS = YES UML_LOOK = NO TEMPLATE_RELATIONS = YES INCLUDE_GRAPH = YES INCLUDED_BY_GRAPH = YES CALL_GRAPH = YES GRAPHICAL_HIERARCHY = YES +DIRECTORY_GRAPH = YES DOT_IMAGE_FORMAT = png -DOT_PATH = +DOT_PATH = C:/Programme/Grafik/GraphViz/Graphviz/bin DOTFILE_DIRS = MAX_DOT_GRAPH_WIDTH = 1024 MAX_DOT_GRAPH_HEIGHT = 1024 MAX_DOT_GRAPH_DEPTH = 1000 +DOT_TRANSPARENT = NO +DOT_MULTI_TARGETS = NO GENERATE_LEGEND = YES DOT_CLEANUP = YES #--------------------------------------------------------------------------- Modified: trunk/FEAPI/doc/doxyconfigPlug =================================================================== --- trunk/FEAPI/doc/doxyconfigPlug 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/doc/doxyconfigPlug 2006-03-15 14:24:19 UTC (rev 66) @@ -1,11 +1,11 @@ -# Doxyfile 1.3.9.1 +# Doxyfile 1.4.5 #--------------------------------------------------------------------------- # Project related configuration options #--------------------------------------------------------------------------- PROJECT_NAME = "FEAPI Feature Extraction Plugin documentation" PROJECT_NUMBER = -OUTPUT_DIRECTORY = ../doc +OUTPUT_DIRECTORY = CREATE_SUBDIRS = NO OUTPUT_LANGUAGE = English USE_WINDOWS_ENCODING = YES @@ -32,12 +32,14 @@ MULTILINE_CPP_IS_BRIEF = YES DETAILS_AT_TOP = YES INHERIT_DOCS = YES -DISTRIBUTE_GROUP_DOC = NO +SEPARATE_MEMBER_PAGES = NO TAB_SIZE = 4 ALIASES = "\"_THE_PLUGIN_CLASS=CFindAbsoluteMax\"" \ CFindAbsoluteMax=_THE_PLUGIN_CLASS OPTIMIZE_OUTPUT_FOR_C = NO OPTIMIZE_OUTPUT_JAVA = NO +BUILTIN_STL_SUPPORT = NO +DISTRIBUTE_GROUP_DOC = NO SUBGROUPING = YES #--------------------------------------------------------------------------- # Build related configuration options @@ -67,6 +69,7 @@ MAX_INITIALIZER_LINES = 30 SHOW_USED_FILES = YES SHOW_DIRECTORIES = YES +FILE_VERSION_FILTER = #--------------------------------------------------------------------------- # configuration options related to warning and progress messages #--------------------------------------------------------------------------- @@ -74,18 +77,22 @@ WARNINGS = YES WARN_IF_UNDOCUMENTED = NO WARN_IF_DOC_ERROR = YES +WARN_NO_PARAMDOC = NO WARN_FORMAT = "$file:$line: $text" WARN_LOGFILE = warn.log #--------------------------------------------------------------------------- # configuration options related to the input files #--------------------------------------------------------------------------- -INPUT = ../doc/docugenPlug.txt \ - ../src/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.h \ - ../src/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.cpp \ - ../src/FEAPI/FEAPIPluginBase.cpp \ - ../src/incl/FEAPIPluginBase.h \ - ../incl/FEAPI.h \ - ../src/FEAPI/FEAPI.cpp +INPUT = docugenPlug.txt \ + ../sdk/plugin/src/FEAPIPluginBase.cpp \ + ../sdk/plugin/include/FEAPIPluginBase.h \ + ../include/FEAPI.h \ + ../sdk/plugin/include/FEAPIEntryPoints.h \ + ../examples/plugin/FEAPIExamplePluginFindRms \ + ../examples/plugin/FEAPIExamplePluginFindMax \ + ../examples/plugin/FEAPIExamplePluginLoudness \ + ../examples/plugin/FEAPIExamplePluginSpectral \ + ../examples/plugin/FEAPIExamplePluginZeroCrossings FILE_PATTERNS = *.h \ *.hpp \ *.txt \ @@ -109,6 +116,7 @@ STRIP_CODE_COMMENTS = YES REFERENCED_BY_RELATION = YES REFERENCES_RELATION = YES +USE_HTAGS = NO VERBATIM_HEADERS = YES #--------------------------------------------------------------------------- # configuration options related to the alphabetical class index @@ -214,18 +222,22 @@ HAVE_DOT = YES CLASS_GRAPH = YES COLLABORATION_GRAPH = YES +GROUP_GRAPHS = YES UML_LOOK = NO TEMPLATE_RELATIONS = YES INCLUDE_GRAPH = YES INCLUDED_BY_GRAPH = YES CALL_GRAPH = YES GRAPHICAL_HIERARCHY = YES +DIRECTORY_GRAPH = YES DOT_IMAGE_FORMAT = png -DOT_PATH = +DOT_PATH = C:/Programme/Grafik/GraphViz/Graphviz/bin DOTFILE_DIRS = MAX_DOT_GRAPH_WIDTH = 1024 MAX_DOT_GRAPH_HEIGHT = 1024 MAX_DOT_GRAPH_DEPTH = 1000 +DOT_TRANSPARENT = NO +DOT_MULTI_TARGETS = NO GENERATE_LEGEND = YES DOT_CLEANUP = YES #--------------------------------------------------------------------------- Modified: trunk/FEAPI/examples/host/Host_C/FEAPIExampleHost_C.cpp =================================================================== --- trunk/FEAPI/examples/host/Host_C/FEAPIExampleHost_C.cpp 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/examples/host/Host_C/FEAPIExampleHost_C.cpp 2006-03-15 14:24:19 UTC (rev 66) @@ -50,6 +50,7 @@ * * @param **pcInputPath : input audio file path, to be written * @param **pcOutputPath : output text path, to be written + * @param *pbSilentMode : bool if in silent mode or not, to be written * @param argc : * @param *argv[] : * @@ -105,7 +106,7 @@ float *pfDataInterleaved = 0, **ppfDataSorted = 0, **ppfResult = 0; - FEAPI_ModuleHandle_t hDllHandle = 0; + FEAPI_ModuleHandle_t hLibraryHandle = 0; FEAPI_PluginFileNames_t *pCurrentPlugin = 0; @@ -185,13 +186,13 @@ pCurrentPlugin = pCurrentPlugin->pNextPlugin; } - // load plugin dll - hDllHandle = 0; - LoadPluginModule (pCurrentPlugin->acFilename, &hDllHandle); - if (!hDllHandle) + // load plugin library + hLibraryHandle = 0; + LoadPluginModule (pCurrentPlugin->acFilename, &hLibraryHandle); + if (!hLibraryHandle) return -1; else - GetFunctionPointers (hDllHandle, &stPluginFunctions); + GetFunctionPointers (hLibraryHandle, &stPluginFunctions); // open input audio file if (pcInputPath == 0) @@ -491,7 +492,7 @@ else fprintf (stdout, " Failed\n"); - UnloadPluginModule (hDllHandle); + UnloadPluginModule (hLibraryHandle); // free allocated memory for (i = 0; i < iNumResults; i++) Modified: trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.cpp =================================================================== --- trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.cpp 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.cpp 2006-03-15 14:24:19 UTC (rev 66) @@ -33,35 +33,6 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author$ -// $Date$ -// -// $Log$ -// Revision 1.1.2.2 2006/01/19 13:27:13 remymuller -// directory reorganization -// -// Revision 1.4 2006/01/18 11:46:52 remymuller -// removed itoa with sprintf -// -// Revision 1.3 2005/07/11 16:56:54 alex_lerch -// - minor changes -// -// Revision 1.2 2005/05/20 17:21:07 alex_lerch -// - usage of strings instead of chars -// - cosmetic changes -// -// Revision 1.1.1.1 2005/03/30 14:54:40 alex_lerch -// first draft version requiring several updates: -// - interface check -// - check of plugin base class -// - implementation of host base class -// - update of outdated documentation -// -// -//////////////////////////////////////////////////////////////////////////////////// #include <string> @@ -104,7 +75,7 @@ #define _FEATURE_SAMPLERATE -1 // output sample rate equals input block length -_THE_PLUGIN_CLASS::_THE_PLUGIN_CLASS () : CFeatureExtractBase() +CFindAbsoluteMax::CFindAbsoluteMax () : CFeatureExtractBase() { // we have no special setting, so the number of parameters is zero in this case @@ -127,7 +98,7 @@ } -_THE_PLUGIN_CLASS::~_THE_PLUGIN_CLASS () +CFindAbsoluteMax::~CFindAbsoluteMax () { // destroy feature vector if (m_pfMaxValue) @@ -141,7 +112,7 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::InitializePlugin (float fInputSampleRate, +FEAPI_Error_t CFindAbsoluteMax::InitializePlugin (float fInputSampleRate, int iNumberOfAudioChannels, int iHostApiMajorVersion, FEAPI_UserData_t *pstUserData) @@ -173,7 +144,7 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::GetPluginResultDescription (int iResultIndex, FEAPI_SignalDescription_t *pstResultDescription) +FEAPI_Error_t CFindAbsoluteMax::GetPluginResultDescription (int iResultIndex, FEAPI_SignalDescription_t *pstResultDescription) { // the description is for all results identical in this case // only the channel number changes (channel number equals feature number for this plugin) @@ -193,7 +164,7 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::GetPluginInputDescription (int iInputIndex, FEAPI_SignalDescription_t *pstInputDescription) +FEAPI_Error_t CFindAbsoluteMax::GetPluginInputDescription (int iInputIndex, FEAPI_SignalDescription_t *pstInputDescription) { // the description is for all inputs identical in this case // only the channel number changes (channel number equals feature number for this plugin) @@ -223,41 +194,41 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::GetPluginParameterDescription (int iParameterIndex, FEAPI_ParameterDescription_t *pstParameterDescription) +FEAPI_Error_t CFindAbsoluteMax::GetPluginParameterDescription (int iParameterIndex, FEAPI_ParameterDescription_t *pstParameterDescription) { // we don't have any parameters in this plugin return FEAPI_kUnknownError; } -FEAPI_Error_t _THE_PLUGIN_CLASS::SetPluginParameter (int iParameterIndex, float fValue) +FEAPI_Error_t CFindAbsoluteMax::SetPluginParameter (int iParameterIndex, float fValue) { // we don't have any parameters in this plugin return FEAPI_kUnknownError; } -float _THE_PLUGIN_CLASS::GetPluginParameter (int iParameterIndex) +float CFindAbsoluteMax::GetPluginParameter (int iParameterIndex) { // we don't have any parameters in this plugin return -1; } -int _THE_PLUGIN_CLASS::GetPluginResultLatency (int iResultIndex) +int CFindAbsoluteMax::GetPluginResultLatency (int iResultIndex) { //<! \todo format??? return 0; } -FEAPI_Error_t _THE_PLUGIN_CLASS::ProcessPluginDone () +FEAPI_Error_t CFindAbsoluteMax::ProcessPluginDone () { // we don't have to do anything special here return FEAPI_kNoError; } -FEAPI_Error_t _THE_PLUGIN_CLASS::ProcessPlugin (const float **ppfInputBuffer, const FEAPI_TimeStamp_t *ptTimeStamps, int iNumberOfFrames) +FEAPI_Error_t CFindAbsoluteMax::ProcessPlugin (const float **ppfInputBuffer, const FEAPI_TimeStamp_t *ptTimeStamps, int iNumberOfFrames) { int iCh, iIdx; @@ -280,7 +251,7 @@ return FEAPI_kNoError; } -int _THE_PLUGIN_CLASS::GetPluginSizeOfResult (int iResultIndex) +int CFindAbsoluteMax::GetPluginSizeOfResult (int iResultIndex) { if (iResultIndex >= m_iNumberOfResults) return -1; @@ -292,7 +263,7 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::GetPluginResult (int iResultIndex, float *pfResult, FEAPI_TimeStamp_t *ptTimeStamp) +FEAPI_Error_t CFindAbsoluteMax::GetPluginResult (int iResultIndex, float *pfResult, FEAPI_TimeStamp_t *ptTimeStamp) { if ((iResultIndex >= m_iNumberOfResults) || (!m_pbIHaveResults[iResultIndex])) return FEAPI_kUnknownError; @@ -307,7 +278,7 @@ } -FEAPI_Error_t _THE_PLUGIN_CLASS::ResetPlugin () +FEAPI_Error_t CFindAbsoluteMax::ResetPlugin () { int i; @@ -318,7 +289,7 @@ } -float _THE_PLUGIN_CLASS::GetPluginProperty ( FEAPI_PluginProperty_t ePluginProperty) +float CFindAbsoluteMax::GetPluginProperty ( FEAPI_PluginProperty_t ePluginProperty) { switch (ePluginProperty) { @@ -366,7 +337,7 @@ extern "C" { #endif -FEAPI_ENTRY_POINTS(_THE_PLUGIN_CLASS) +FEAPI_ENTRY_POINTS(CFindAbsoluteMax) #ifdef __cplusplus } Modified: trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.h =================================================================== --- trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.h 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindMax/FEAPIExamplePluginFindMax.h 2006-03-15 14:24:19 UTC (rev 66) @@ -33,31 +33,6 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author$ -// $Date$ -// -// $Log$ -// Revision 1.1.2.2 2006/01/19 13:27:13 remymuller -// directory reorganization -// -// Revision 1.3 2005/06/20 16:45:22 alex_lerch -// - changed variable name in function declaration for doxygen consistency -// -// Revision 1.2 2005/05/20 17:20:14 alex_lerch -// - adde missing functions -// -// Revision 1.1.1.1 2005/03/30 14:54:40 alex_lerch -// first draft version requiring several updates: -// - interface check -// - check of plugin base class -// - implementation of host base class -// - update of outdated documentation -// -// -//////////////////////////////////////////////////////////////////////////////////// #if !defined(FIND_ABSOLUTE_MAX_HEADER_INCLUDED__) #define FIND_ABSOLUTE_MAX_HEADER_INCLUDED__ @@ -65,8 +40,6 @@ #include "FEAPIPluginBase.h" -#define _THE_PLUGIN_CLASS CFindAbsoluteMax // change this class name to your class - /*! the class ::CFindAbsoluteMax is an example class to demonstrate how to implement a plug-in for the Feature Extraction API. The functionality of this plug-in is to find @@ -74,13 +47,13 @@ results in dBFS. */ -class _THE_PLUGIN_CLASS : public CFeatureExtractBase +class CFindAbsoluteMax : public CFeatureExtractBase { public: - _THE_PLUGIN_CLASS (); + CFindAbsoluteMax (); - virtual ~_THE_PLUGIN_CLASS (); + virtual ~CFindAbsoluteMax (); //////////////////////////////////////////////////////////////////////////////////////// Modified: trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.cpp =================================================================== --- trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.cpp 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.cpp 2006-03-15 14:24:19 UTC (rev 66) @@ -1,5 +1,5 @@ //////////////////////////////////////////////////////////////////////////////////// -// /*! \file FEAPIExamplePluginFindMax.cpp: \brief implementation of the CFindAbsoluteMax class. */ +// /*! \file FEAPIExamplePluginFindRms.cpp: \brief implementation of the CFindAbsoluteRms class. */ // // Copyright (c) 2004-2005, Alexander Lerch, zplane.development GbR // All rights reserved. @@ -33,18 +33,6 @@ // POSSIBILITY OF SUCH DAMAGE. // //////////////////////////////////////////////////////////////////////////////////// -// CVS INFORMATION -// -// $RCSfile$ -// $Author: remymuller $ -// $Date: 2006-01-19 13:22:21 +0100 (do, 19 jan 2006) $ -// -// $Log$ -// Revision 1.1.2.1 2006/01/19 12:22:21 remymuller -// moved example into examples folder -// -// -//////////////////////////////////////////////////////////////////////////////////// #include <string> #include <iostream> @@ -53,6 +41,7 @@ #include "FEAPI.h" #include "FEAPIExamplePluginFindRms.h" +#include "FEAPIEntryPoints.h" #ifndef FLT_MAX #define FLT_MAX 3.402823466e+38F @@ -327,8 +316,6 @@ /////////////////////////////////////// // entry points -#include "FEAPIEntryPoints.h" - #ifdef __cplusplus extern "C" { #endif Modified: trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.h =================================================================== --- trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.h 2006-03-14 16:49:03 UTC (rev 65) +++ trunk/FEAPI/examples/plugin/FEAPIExamplePluginFindRms/FEAPIExamplePluginFindRms.h 2006-03-15 14:24:19 UTC (rev 66) @@ -1,5 +1,5 @@ ////////////////////////////////////////////////////////////... [truncated message content] |
From: <fea...@li...> - 2006-04-07 10:11:09
|
Revision: 76 Author: alex_lerch Date: 2006-04-07 03:10:55 -0700 (Fri, 07 Apr 2006) ViewCVS: http://svn.sourceforge.net/feapi/?rev=76&view=rev Log Message: ----------- - minor documentation update Modified Paths: -------------- trunk/FEAPI/doc/docugenAPI.txt trunk/FEAPI/doc/html/index.html This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fea...@li...> - 2006-04-10 09:33:04
|
Revision: 78 Author: KoenTanghe Date: 2006-04-10 02:32:48 -0700 (Mon, 10 Apr 2006) ViewCVS: http://svn.sourceforge.net/feapi/?rev=78&view=rev Log Message: ----------- Added explicit notice from API docs into code docs for Create-/constructor-related functions (regarding not doing heavy-weight stuff there, but in Initialize-functions). Modified Paths: -------------- trunk/FEAPI/doc/docugenAPI.txt trunk/FEAPI/include/FEAPI.h trunk/FEAPI/sdk/host/include/FEAPIPluginProxy.h trunk/FEAPI/sdk/plugin/include/FEAPIPluginBase.h This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fea...@li...> - 2006-04-10 10:14:36
|
Revision: 79 Author: KoenTanghe Date: 2006-04-10 03:14:28 -0700 (Mon, 10 Apr 2006) ViewCVS: http://svn.sourceforge.net/feapi/?rev=79&view=rev Log Message: ----------- Added: - ReadMe.txt file with quick steps about generating the documentation - GenerateDocs_Win.bat script to generate the docs by just double-clicking (if someone else knows how to write a simple Mac or Linux script for this, please go ahead) Added Paths: ----------- trunk/FEAPI/doc/GenerateDocs_Win.bat trunk/FEAPI/doc/ReadMe.txt This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: Code r. c. l. <fea...@li...> - 2006-06-02 10:10:27
|
Revision: 96 Author: KoenTanghe Date: 2006-06-02 03:10:21 -0700 (Fri, 02 Jun 2006) ViewCVS: http://svn.sourceforge.net/feapi/?rev=96&view=rev Log Message: ----------- removed hard paths to C:/programme/... stuff (for the dot tool) --> just make sure the path to the tool is on your OS search path (PATH environment variable on Windows) --> on SF, both dot and doxygen are on the search path already by default Modified Paths: -------------- trunk/FEAPI/doc/doxyconfigAPI trunk/FEAPI/doc/doxyconfigHost trunk/FEAPI/doc/doxyconfigPlug This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |