From a1a3ece09d2adbf4d3ce45f7b4689045634c4a1e Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 11:52:36 -0400 Subject: [PATCH 1/8] cmDocMain.h : Deleted. --- src/cmDocMain.h | 54 ------------------------------------------------- 1 file changed, 54 deletions(-) delete mode 100644 src/cmDocMain.h diff --git a/src/cmDocMain.h b/src/cmDocMain.h deleted file mode 100644 index 78f9263..0000000 --- a/src/cmDocMain.h +++ /dev/null @@ -1,54 +0,0 @@ -/*! \mainpage cm Manual - - To modify this page edit cmDocMain.h - - \section building Building - \subsection debug_mode Debug/Release Compile Mode - By default the project builds in debug mode. To build in release mode define NDEBUG - on the compiler command line. The existence of NDEBUG is tested in cmGlobal.h and - the value of the preprocessor variable #cmDEBUG_FL is set to 0 if NDEBUG was defined - and 1 otherwise. Code which depends on the debug/release mode then tests the value of - #cmDEBUG_FL. - - - The cm library is a set of C routines for working audio signals. - - \section foundation Foundation - \subsection mem Memory Management - \subsection output Output and Error Reporting - \subsection files File Management - \subsection cfg Program Configuration and Data - - - - \subsection step1 Step 1: Opening the box - - */ - - -/*! - - -\defgroup base Base -@{ - -@} - -\defgroup rt Real-time -@{ -@} - -\defgroup audio Audio -@{ - -@} - -\defgroup dsp Signal Processing -@{ -@} - -\defgroup gr Graphics -@{ -@} - - */ From 7b32da2c04e186f228711180a97d2623e3ec478e Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 11:59:12 -0400 Subject: [PATCH 2/8] Many documentation string additions and updates. --- src/app/cmMidiScoreFollow.h | 12 + src/app/cmScoreMatchGraphic.h | 4 + src/app/cmXScore.h | 13 + src/cmApBuf.c | 10 +- src/cmAudioPort.h | 2 +- src/cmAudioSys.c | 12 +- src/cmJson.c | 5 +- src/cmKeyboard.h | 2 +- src/cmMidiPort.h | 2 +- src/cmPP_NARG.h | 5 +- src/cmPrefix.h | 3 +- src/cmProcTest.c | 1 - src/cmProcTest.h | 4 + src/cmRptFile.h | 4 + src/cmSerialPort.h | 4 + src/cmSvgWriter.h | 5 + src/cmSyncRecd.h | 5 +- src/cmVectOpsDocOut.h | 990 ++++++++++++++++++++++++++++++++ src/cmXml.h | 4 + src/dsp/cmDspBuiltIn.h | 4 + src/dsp/cmDspCtx.h | 4 + src/dsp/cmDspFx.h | 4 + src/dsp/cmDspPgm.h | 4 +- src/dsp/cmDspPgmKr.h | 4 + src/dsp/cmDspPgmKrChain.h | 3 + src/dsp/cmDspPgmPPMain.h | 3 + src/dsp/cmDspUi.h | 2 + src/vop/cmVectOpsDoc.h | 13 +- src/vop/cmVectOpsRICode.h | 196 ++++--- src/vop/cmVectOpsRIHdr.h | 182 ++++-- src/vop/cmVectOpsTemplateCode.h | 763 ++++++++++++------------ src/vop/cmVectOpsTemplateHdr.h | 733 +++++++++++++---------- 32 files changed, 2131 insertions(+), 871 deletions(-) create mode 100644 src/cmVectOpsDocOut.h diff --git a/src/app/cmMidiScoreFollow.h b/src/app/cmMidiScoreFollow.h index 838c728..8796c20 100644 --- a/src/app/cmMidiScoreFollow.h +++ b/src/app/cmMidiScoreFollow.h @@ -5,6 +5,17 @@ #ifdef __cplusplus extern "C" { #endif + + //( { file_desc:"Score follow a MIDI files." kw[score] } + // + // This function uses a CSV score file generated from cmXScoreTest() to score follow a MIDI file. + // Output filesL + // - MIDI file with velocities from the score applied to the associated notes in the MIDI file. + // - A text file, for use with cmTimeLine, which describes the bar positions as absolute times into the score. + // - An SVG file which shows the score match results over time for each note in the score. + // - A report file which lists the score match status over time. + + enum { @@ -24,6 +35,7 @@ extern "C" { const cmChar_t* midiOutFn, // (optional) midiFn with apply sostenuto and velocities from the score to the MIDI file const cmChar_t* tlBarOutFn // (optional) bar positions sutiable for use in a cmTimeLine description file. ); + //) #ifdef __cplusplus } diff --git a/src/app/cmScoreMatchGraphic.h b/src/app/cmScoreMatchGraphic.h index 130d315..02258fc 100644 --- a/src/app/cmScoreMatchGraphic.h +++ b/src/app/cmScoreMatchGraphic.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"Implements the functionality of cmMidiScoreFollowMain()." kw[score] } + enum { kOkSmgRC = cmOkRC, @@ -34,6 +36,8 @@ extern "C" { // from from score into MIDI file and then write the updated MIDI // file to 'newMidiFn'. cmSmgRC_t cmScoreMatchGraphicUpdateMidiFromScore( cmCtx_t* ctx, cmSmgH_t h, const cmChar_t* newMidiFn ); + + //) #ifdef __cplusplus } diff --git a/src/app/cmXScore.h b/src/app/cmXScore.h index c412368..b7bb049 100644 --- a/src/app/cmXScore.h +++ b/src/app/cmXScore.h @@ -5,6 +5,17 @@ extern "C" { #endif + //( { file_desc:"Process a Music XML score in a variety of ways." kw[score] } + + //$ + // cmScoreTest() performs a the following functions: + // - Parses Music XML files into a text (edit) file. + // - The 'edit' file can then be manually edited to modify and add information to the score. + // - The modified 'edit' file can then be used to generate a CSV file + // suitable for use with cmScore(), a MIDI file which can render the modified score, + // and a SVG file which will display the score as a piano roll. + // + enum { kOkXsRC = cmOkRC, @@ -73,6 +84,8 @@ extern "C" { // Set begMeasNumb to the first measure the to be written to the output csv, MIDI and SVG files. // Set begBPM to 0 to use the tempo from the score otherwise set it to the tempo at begMeasNumb. cmXsRC_t cmXScoreTest( cmCtx_t* ctx, const cmChar_t* xmlFn, const cmChar_t* reorderFn, const cmChar_t* csvOutFn, const cmChar_t* midiOutFn, const cmChar_t* svgOutFn, bool reportFl, int begMeasNumb, int begBPM, bool svgStandAloneFl, bool svgPanZoomFl, bool damperRptFl ); + + //) #ifdef __cplusplus } diff --git a/src/cmApBuf.c b/src/cmApBuf.c index 4617a83..7036054 100644 --- a/src/cmApBuf.c +++ b/src/cmApBuf.c @@ -1071,7 +1071,12 @@ void cmApBufReport( cmRpt_t* rpt ) } } -/// [cmApBufExample] +//{ { label:cmApBufExample } +//( +// cmApBufTest() demonstrates the audio buffer usage. +//) + +//( void cmApBufTest( cmRpt_t* rpt ) { @@ -1172,6 +1177,7 @@ void cmApBufTest( cmRpt_t* rpt ) cmApBufFinalize(); } -/// [cmApBufExample] +//) +//} diff --git a/src/cmAudioPort.h b/src/cmAudioPort.h index 21fe271..4eedbd1 100644 --- a/src/cmAudioPort.h +++ b/src/cmAudioPort.h @@ -1,4 +1,4 @@ -//( { file_desc: "Cross platform audio device interface." kw:[audio rt] } +//( { file_desc: "Cross platform audio device interface." kw:[audio rt devices] } // // This interface provides data declarations for platform dependent // audio I/O functions. The implementation for the functions are diff --git a/src/cmAudioSys.c b/src/cmAudioSys.c index 215390f..8fe484a 100644 --- a/src/cmAudioSys.c +++ b/src/cmAudioSys.c @@ -1157,11 +1157,16 @@ unsigned cmAudioSysSubSystemCount( cmAudioSysH_t h ) //=========================================================================================================================== // -// cmAsTest() +// cmAudioSysTest() // -/// [cmAudioSysTest] +//{ { label:cmAudioSysTest } +//( +// cmAudioSysTest() demonstrates the audio system usage. +//) +//( + typedef struct { double hz; // current synth frq @@ -1463,4 +1468,5 @@ void cmAudioSysTest( cmRpt_t* rpt, int argc, const char* argv[] ) } -/// [cmAudioSysTest] +//) +//} diff --git a/src/cmJson.c b/src/cmJson.c index 58c210b..701bbdd 100644 --- a/src/cmJson.c +++ b/src/cmJson.c @@ -3994,7 +3994,8 @@ void _cmJsonTestPrint( void* userPtr, const cmChar_t* text ) //( // cmJsonTest() demonstrates some JSON tree operations. //) -//[ + +//( cmJsRC_t cmJsonTest( const char* fn, cmCtx_t* ctx ) { cmJsRC_t rc = kOkJsRC; @@ -4076,5 +4077,5 @@ cmJsRC_t cmJsonTest( const char* fn, cmCtx_t* ctx ) return rc == kOkJsRC ? rc1 : rc; } -//] +//) //} diff --git a/src/cmKeyboard.h b/src/cmKeyboard.h index 13e9a93..1ca3ade 100644 --- a/src/cmKeyboard.h +++ b/src/cmKeyboard.h @@ -5,7 +5,7 @@ extern "C" { #endif - //( { file_desc:"Query and get keypresses directly from the console." kw:[system] } + //( { file_desc:"Query and get keypresses directly from the console." kw:[system devices] } enum { diff --git a/src/cmMidiPort.h b/src/cmMidiPort.h index bb4a2aa..abb44b1 100644 --- a/src/cmMidiPort.h +++ b/src/cmMidiPort.h @@ -5,7 +5,7 @@ extern "C" { #endif - //( { file_desc:"Device independent MIDI port related code." kw:[midi]} + //( { file_desc:"Device independent MIDI port related code." kw:[midi devices]} typedef unsigned cmMpRC_t; diff --git a/src/cmPP_NARG.h b/src/cmPP_NARG.h index edf54ec..498d0e2 100644 --- a/src/cmPP_NARG.h +++ b/src/cmPP_NARG.h @@ -1,7 +1,8 @@ #ifndef cmPP_NARG_H #define cmPP_NARG_H - +//( { file_desc:"Var-args argument counter. " kw:[base] } +// // Taken from here: // https://groups.google.com/forum/#!topic/comp.std.c/d-6Mj5Lko_s // and here: @@ -43,3 +44,5 @@ 9,8,7,6,5,4,3,2,1,0 #endif + +//) diff --git a/src/cmPrefix.h b/src/cmPrefix.h index 948fcda..4a88c53 100644 --- a/src/cmPrefix.h +++ b/src/cmPrefix.h @@ -5,8 +5,9 @@ extern "C" { #endif + //( { file_desc:"Global prefix header for the 'cm' library. Currently empty." kw:[base] } - + //) #ifdef __cplusplus } diff --git a/src/cmProcTest.c b/src/cmProcTest.c index 81da1e3..890dd26 100644 --- a/src/cmProcTest.c +++ b/src/cmProcTest.c @@ -28,7 +28,6 @@ #include // time() - void cmTestPrint( cmRpt_t* rpt, const char* fmt, ... ) { va_list vl; diff --git a/src/cmProcTest.h b/src/cmProcTest.h index f508853..23d7d0b 100644 --- a/src/cmProcTest.h +++ b/src/cmProcTest.h @@ -5,10 +5,14 @@ extern "C" { #endif + //( { file_desc: "Some obsolete test stub functions. See the cmtools project for a complete set of test and example functions." kw:[proc]} + void cmProcTestNoInit( cmCtx_t* ctx ); void cmProcTestGnuPlot( cmCtx_t* ctx ); void cmProcTest( cmCtx_t* ctx ); + //) + #ifdef __cplusplus } #endif diff --git a/src/cmRptFile.h b/src/cmRptFile.h index 0821fd5..d8d9109 100644 --- a/src/cmRptFile.h +++ b/src/cmRptFile.h @@ -4,6 +4,8 @@ #ifdef __cplusplus extern "C" { #endif + + //( { file_desc: "The cmRptFile provides a cmRpt class which outputs to a file." kw:[base]} enum { @@ -23,6 +25,8 @@ extern "C" { cmRpt_t* cmRptFileRpt( cmRptFileH_t h ); + //) + #ifdef __cplusplus } #endif diff --git a/src/cmSerialPort.h b/src/cmSerialPort.h index 3ed5dc2..a44c614 100644 --- a/src/cmSerialPort.h +++ b/src/cmSerialPort.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"Serial port interface." kw[system devices rt] } + typedef unsigned cmSeRC_t; enum @@ -86,6 +88,8 @@ extern "C" { cmSeRC_t cmSePortTest(cmCtx_t* ctx); + //) + #ifdef __cplusplus } #endif diff --git a/src/cmSvgWriter.h b/src/cmSvgWriter.h index d8a4ec9..0e9db43 100644 --- a/src/cmSvgWriter.h +++ b/src/cmSvgWriter.h @@ -5,6 +5,9 @@ extern "C" { #endif + //( { file_desc:"SVG file writer." kw[file plot] } + + enum { kOkSvgRC = cmOkRC, @@ -31,6 +34,8 @@ enum // Both the CSS file and svg-pan-zoom.min.js should therefore be in the same directory // as the output HTML file. cmSvgRC_t cmSvgWriterWrite( cmSvgH_t h, const cmChar_t* cssFn, const cmChar_t* outFn, bool standaloneFl, bool panZoomFl ); + + //) #ifdef __cplusplus } diff --git a/src/cmSyncRecd.h b/src/cmSyncRecd.h index d5fdd1d..f4d18dd 100644 --- a/src/cmSyncRecd.h +++ b/src/cmSyncRecd.h @@ -4,6 +4,8 @@ #ifdef __cplusplus extern "C" { #endif + + //( { file_desc:"Generate time-alignment data between an audio and MIDI file. See cmDspSyncRecd_t." kw[proc] } enum { @@ -27,7 +29,8 @@ extern "C" { cmSyRC_t cmSyncRecdTest( cmCtx_t* ctx ); - + //) + #ifdef __cplusplus } #endif diff --git a/src/cmVectOpsDocOut.h b/src/cmVectOpsDocOut.h new file mode 100644 index 0000000..8f9c189 --- /dev/null +++ b/src/cmVectOpsDocOut.h @@ -0,0 +1,990 @@ +//( { file_desc:"Math vector operations." kw:[vop math] } +//) +//( { label:misc desc:"Miscellaneous vector operations." kw:[vop] } + +// Compute the cummulative sum of sbp[dn]. Equivalent to Matlab cumsum(). +T_t* cmVOT_CumSum(T_t* dbp, unsigned dn, const T_t* sbp ); + +// Returns true if all values in each vector are equal. +bool cmVOT_Equal( const T_t* s0p, const T_t* s1p, unsigned sn ); + +// Same as Matlab linspace() v[i] = i * (limit-1)/n +T_t* cmVOT_LinSpace( T_t* dbp, unsigned dn, T_t base, T_t limit ); + +//====================================================================================================================== +//) + + +//( { label:Print desc:"Vector printing functions." kw:[vop] } +// Setting fieldWidth or decPltCnt to to negative values result in fieldWidth == 10 or decPlCnt == 4 +// +void cmVOT_Printf( cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp, int fieldWidth, int decPlCnt, const char* fmt, unsigned flags ); +void cmVOT_Print( cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp ); +void cmVOT_PrintE( cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp ); + +void cmVOT_PrintLf( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp, unsigned fieldWidth, unsigned decPlCnt, const char* fmt ); +void cmVOT_PrintL( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp ); +void cmVOT_PrintLE( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const T_t* dbp ); +//====================================================================================================================== +//) + + +//( { label:Normalization desc:"Normalization and standardization functions." kw:[vop] } + +// Normalize the vector of proabilities by dividing through by the sum. +// This leaves the relative proportions of each value unchanged while producing a total probability of 1.0. +// +T_t* cmVOT_NormalizeProbabilityVV(T_t* dbp, unsigned dn, const T_t* sbp); +T_t* cmVOT_NormalizeProbability(T_t* dbp, unsigned dn); +T_t* cmVOT_NormalizeProbabilityN(T_t* dbp, unsigned dn, unsigned stride); +// +// Standardize the columns of the matrix by subtracting the mean and dividing by the standard deviation. +// uV[dcn] returns the mean of the data and is optional. +// sdV[dcn] return the standard deviation of the data and is optional. +T_t* cmVOT_StandardizeRows( T_t* dbp, unsigned drn, unsigned dcn, T_t* uV, T_t* sdV ); +T_t* cmVOT_StandardizeCols( T_t* dbp, unsigned drn, unsigned dcn, T_t* uV, T_t* sdV ); +// +// Normalize by dividing through by the max. value. +// dp[] ./= max(dp). Returns the index of the max value. +unsigned cmVOT_NormToMax( T_t* dp, unsigned dn ); +// +// Normalize by dividing through by the max. absolute value. +// db[] .*= fact / abs(max(dp)); +unsigned cmVOT_NormToAbsMax( T_t* dp, unsigned dn, T_t fact ); +//====================================================================================================================== +//) + + +//( { label:"Mean and variance" desc:"Compute mean and variance." kw:[vop] } + +T_t cmVOT_Mean( const T_t* sp, unsigned sn ); +T_t cmVOT_MeanN( const T_t* sp, unsigned sn, unsigned stride ); +// +// Take the mean of each column/row of a matrix. +// Set 'dim' to 0 to return mean of columns else return mean of rows. +T_t* cmVOT_MeanM( T_t* dp, const T_t* sp, unsigned srn, unsigned scn, unsigned dim ); +// +// Take the mean of the first 'cnt' element of each column/row of a matrix. +// Set 'dim' to 0 to return mean of columns else return mean of rows. +// If 'cnt' is greater than the number of elements in the column/row then 'cnt' is +// reduced to the number of elements in the column/row. +T_t* cmVOT_MeanM2( T_t* dp, const T_t* sp, unsigned srn, unsigned scn, unsigned dim, unsigned cnt ); +// +// Find the mean of the data points returned by srcFuncPtr(argPtr,i) and return it in dp[dim]. +// 'dim' is both the size of dp[] and the length of each data point returned by srcFuncPtr(). +// srcFuncPtr() will be called 'cnt' times but it may return NULL on some calls if the associated +// data point should not be included in the mean calculation. +T_t* cmVOT_Mean2( T_t* dp, const T_t* (*srcFuncPtr)(void* arg, unsigned idx ), unsigned dim, unsigned cnt, void* argPtr ); +// +// avgPtr is optional - set to NULL to compute the average +T_t cmVOT_Variance( const T_t* sp, unsigned sn, const T_t* avgPtr ); +T_t cmVOT_VarianceN(const T_t* sp, unsigned sn, unsigned stride, const T_t* avgPtr ); +// +// Set dim=0 to return variance of columns otherwise return variance or rows. +T_t* cmVOT_VarianceM(T_t* dp, const T_t* sp, unsigned srn, unsigned scn, const T_t* avgPtr, unsigned dim ); +//====================================================================================================================== +//) + + +//( { label:"Covariance" desc:"Matrix covariance" kw:[vop] } + +// Calculate the sample covariance matrix from a set of Gaussian distributed multidimensional data. +// sp[dn,scn] is the data set. +// dn is the dimensionality of the data. +// scn is the count of data points +// up[dn] is an optional mean vector. If up == NULL then the mean of the data is calculated internally. +// selIdxV[scn] can be used to select a subset of datapoints to process. +// If selIdxV[] is non-NULL then only columns where selIdxV[i]==selKey will be processed. +// +// dp[dn,dn] = covar( sp[dn,scn], u[dn] ) +void cmVOT_GaussCovariance(T_t* dp, unsigned dn, const T_t* sp, unsigned scn, const T_t* up, const unsigned* selIdxV, unsigned selKey ); + +// Calculate the sample covariance matrix. +// dp[ dn*dn ] - output matrix +// dn - dimensionality of the data +// srcFuncPtr - User defined function which is called to return a pointer to a data vector at index 'idx'. +// The returned data vector must contain 'dn' elements. The function should return NULL +// if the data point associated with 'idx' should not be included in the covariance calculation. +// sn - count of data vectors +// userPtr - User arg. passed to srcFuncPtr. +// uV[ dn ] - mean of the data set (optional) +// Note that this function computes the covariance matrix in 2 serial passes (1 if the mean vector is given) +// through the 'sn' data points. +// The result of this function are identical to the octave cov() function. +void cmVOT_GaussCovariance2(T_t* dp, unsigned dn, const T_t* (*srcFuncPtr)(void* userPtr, unsigned idx), unsigned sn, void* userPtr, const T_t* uV, const unsigned* selIdxV, unsigned selKey ); +//====================================================================================================================== +//) + +//( { label:"Float point normal" desc:"Evaluate the 'normalness of floating point values." kw:[vop] } + +// Returns true if all values are 'normal' according the the C macro 'isnormal'. +// This function will return false if any of the values are zero. +bool cmVOT_IsNormal( const T_t* sp, unsigned sn ); + +// Returns true if all values are 'normal' or zero according the the C macro 'isnormal'. +// This function accepts zeros as normal. +bool cmVOT_IsNormalZ(const T_t* sp, unsigned sn ); + +// Set dp[dn] to the indexes of the non-normal numbers in sp[dn]. +// Returns the count of indexes stored in dp[]. +unsigned cmVOT_FindNonNormal( unsigned* dp, unsigned dn, const T_t* sp ); +unsigned cmVOT_FindNonNormalZ( unsigned* dp, unsigned dn, const T_t* sp ); +//====================================================================================================================== +//) + + +//( { label:"Measure" desc:"Measure features of a vector." kw:[vop] } + +// Successive call to to ZeroCrossCount should preserve the value pointed to by delaySmpPtr. +unsigned cmVOT_ZeroCrossCount( const T_t* sp, unsigned n, T_t* delaySmpPtr); + +// Calculuate the sum of the squares of all elements in bp[bn]. +T_t cmVOT_SquaredSum( const T_t* bp, unsigned bn ); + +// sn must be <= wndSmpCnt. If sn < wndSmpCnt then sp[sn] is treated as a +// a partially filled buffer padded with wndSmpCnt-sn zeros. +// rms = sqrt( sum(sp[1:sn] .* sp[1:sn]) / wndSmpCnt ) +T_t cmVOT_RMS( const T_t* sp, unsigned sn, unsigned wndSmpCnt ); + +// This function handles the case were sn is not an integer multiple of +// wndSmpCnt or hopSmpCnt. In this case the function computes zero +// padded RMS values for windows which go past the end of sp[sn]. +T_t* cmVOT_RmsV( T_t* dp, unsigned dn, const T_t* sp, unsigned sn, unsigned wndSmpCnt, unsigned hopSmpCnt ); + +// Return the magnitude (Euclidean Norm) of a vector. +T_t cmVOT_EuclidNorm( const T_t* sp, unsigned sn ); + +T_t cmVOT_AlphaNorm(const T_t* sp, unsigned sn, T_t alpha ); + +//====================================================================================================================== +//) + + + +//( { label:"Distance" desc:"Calculate various vector distances." kw:[vop] } + +// Return the Itakura-Saito distance between a modelled power spectrum (up) and another power spectrum (sp). +T_t cmVOT_ItakuraDistance( const T_t* up, const T_t* sp, unsigned sn ); + +// Return the cosine distance between two vectors. +T_t cmVOT_CosineDistance( const T_t* s0P, const T_t* s1p, unsigned sn ); + +// Return the Euclidean distance between two vectors +T_t cmVOT_EuclidDistance( const T_t* s0p, const T_t* s1p, unsigned sn ); + +// Return the Manhattan distance between two vectors +T_t cmVOT_L1Distance( const T_t* s0p, const T_t* s1p, unsigned sn ); + +// Return the Mahalanobis distance between a vector and the mean of the distribution. +// The mean vector could be replaced with another vector drawn from the same distribution in which +// case the returned value would reflect the distance between the two vectors. +// 'sn' is the dimensionality of the data. +// up[D] and invCovM[sn,sn] are the mean and inverse of the covariance matrix of the distribution from +// which sp[D] is drawn. +T_t cmVOT_MahalanobisDistance( const T_t* sp, unsigned sn, const T_t* up, const T_t* invCovM ); + +// Return the KL distance between two probability distributions up[sn] and sp[sn]. +// Since up[] and sp[] are probability distributions they must sum to 1.0. +T_t cmVOT_KL_Distance( const T_t* up, const T_t* sp, unsigned sn ); + +// Return the KL distance between a prototype vector up[sn] and another vector sp[sn]. +// This function first normalizes the two vectors to sum to 1.0 before calling +// cmVOT_KL_Distance(up,sp,sn); +T_t cmVOT_KL_Distance2( const T_t* up, const T_t* sp, unsigned sn ); + + +// Measure the Euclidean distance between a vector and all the columns in a matrix. +// If dv[scn] is no NULL then return the Euclidean distance from sv[scn] to each column of sm[srn,scn]. +// The function returns the index of the closest data point (column) in sm[]. +unsigned cmVOT_EuclidDistanceVM( T_t* dv, const T_t* sv, const T_t* sm, unsigned srn, unsigned scn ); + +// Measure the distance between each column in s0M[ rn, s0cn ] and +// each column in s1M[rn, s1cn ]. If dM is non-NULL store the +// result in dM[s1cn, s0cn]. The difference between s0M[:,0] and s1M[:,0] +// is stored in dM[0,0], the diff. between s0M[:,1] and s1M[:,1] is stored +// in dM[1,0], etc. If mvV[s0cn] is non-NULL then minV[i] is set with +// the distance from s0M[:,i] to the nearest column in s1M[]. If miV[s0cn] +// is non-NULL then it is set with the column index of s1M[] which is +// closest to s0M[:,i]. In other words mvV[i] gives the distance to column +// miV[i] from column s0M[:,i]. +// In those cases where the distane from a prototype (centroid) to the data point +// is not the same as from the data point to the centroid then s1M[] is considered +// to hold the prototypes and s0M[] is considered to hold the data points. +// The distance function returns the distance from a prototype 'cV[dimN]' to +// an datapoint dV[dimN]. 'dimN' is the dimensionality of the data vector +// and is threfore equal to 'rn'. +void cmVOT_DistVMM( + T_t* dM, // dM[s1cn,s0cn] return distance mtx (optional) + T_t* mvV, // mvV[s0cn] distance to closest data point in s0M[]. (optional) + unsigned* miV, // miV[s0cn] column index into s1M[] of closest data point to s0M[:,i]. (optional) + unsigned rn, // dimensionality of the data and the row count for s0M[] and s1M[] + const T_t* s0M, // s0M[rn,s0cn] contains one data point per column + unsigned s0cn, // count of data points (count of columns in s0M[] + const T_t* s1M, // s1M[rn,s1cn] contains one prototype per column + unsigned s1cn, // count of prototypes (count of columns in s1m[] + T_t (*distFunc)( void* userPtr, const T_t* cV, const T_t* dV, unsigned dimN ), + void* userPtr ); + +//====================================================================================================================== +//) + +//( { label:"Select columns" desc:"Select columns based on distance." kw:[vop] } + +// Select 'selIdxN' columns from sM[srn,scn]. +// dM[srn,selIdxN] receives copies of the selected columns. +// selIdxV[selIdxN] receives the column indexes of the selected columns. +// Both dM[] and selIdxV[] are optional. +// In each case the first selected point is chosen at random. +// SelectRandom() then selects the following selIdxN-1 points at random. +// SelectMaxDist() selects the next selIdxN-1 points by selecting +// the point whose combined distance to the previously selected points +// is greatest. SelectMaxAvgDist() selectes the points whose combined +// average distance is greatest relative the the previously selected +// points. +void cmVOT_SelectRandom( T_t* dM, unsigned* selIdxV, unsigned selIdxN, const T_t* sM, unsigned srn, unsigned scn ); +void cmVOT_SelectMaxDist( T_t* dM, unsigned* selIdxV, unsigned selIdxN, const T_t* sM, unsigned srn, unsigned scn, T_t (*distFunc)( void* userPtr, const T_t* s0V, const T_t* s1V, unsigned sn ), void* distUserPtr ); +void cmVOT_SelectMaxAvgDist( T_t* dM, unsigned* selIdxV, unsigned selIdxN, const T_t* sM, unsigned srn, unsigned scn, T_t (*distFunc)( void* userPtr, const T_t* s0V, const T_t* s1V, unsigned sn ), void* distUserPtr ); + +//====================================================================================================================== +//) + +//( { label:"Matrix multiplication" desc:"Various matrix multiplication operations." kw:[vop] } + +// Return the sum of the products (dot product) +T_t cmVOT_MultSumVV( const T_t* s0p, const T_t* s1p, unsigned sn ); +T_t cmVOT_MultSumVS( const T_t* s0p, unsigned sn, T_t s ); + +// Number of elements in the dest vector is expected to be the same +// as the number of source matrix rows. +// mcn gives the number of columns in the source matrix which is +// expected to match the number of elements in the source vector. +// dbp[dn,1] = mp[dn,mcn] * vp[mcn,1] +T_t* cmVOT_MultVMV( T_t* dbp, unsigned dn, const T_t* mp, unsigned mcn, const T_t* vp ); + +// Multiply a row vector with a matrix to produce a row vector. +// dbp[1,dn] = v[1,vn] * m[vn,dn] +T_t* cmVOT_MultVVM( T_t* dbp, unsigned dn, const T_t* vp, unsigned vn, const T_t* mp ); + +// Same as MultVMtV() except M is transposed as part of the multiply. +// mrn gives the number of rows in m[] and number of elements in vp[] +// dpb[dn] = mp[mrn,dn] * vp[mrn] +T_t* cmVOT_MultVMtV( T_t* dbp, unsigned dn, const T_t* mp, unsigned mrn, const T_t* vp ); + +// Same as MultVMV() but where the matrix is diagonal. +T_t* cmVOT_MultDiagVMV( T_t* dbp, unsigned dn, const T_t* mp, unsigned mcn, const T_t* vp ); + +// Generalized matrix multiply. +// If transposition is selected for M0 or M1 then the given dimension represent the size of the matrix 'after' the transposion. +// d[drn,dcn] = alpha * op(m0[drn,m0cn_m1rn]) * op(m1[m0cn_m1rn,dcn]) + beta * d[drn,dcn] +/// See enum { kTranpsoseM0Fl=0x01, kTransposeM1Fl=0x02 } in cmVectOps for flags. +T_t* cmVOT_MultMMM1(T_t* dbp, unsigned drn, unsigned dcn, T_t alpha, const T_t* m0, const T_t* m1, unsigned m0cn_m1rn, T_t beta, unsigned flags ); + +// Same a cmVOT_MultMMM1 except allows the operation on a sub-matrix by providing the physical (memory) row count rather than the logical (matrix) row count. +T_t* cmVOT_MultMMM2(T_t* dbp, unsigned drn, unsigned dcn, T_t alpha, const T_t* m0, const T_t* m1, unsigned m0cn_m1rn, T_t beta, unsigned flags, unsigned dprn, unsigned m0prn, unsigned m1prn ); + +// d[drn,dcn] = m0[drn,m0cn] * m1[m1rn,dcn] +T_t* cmVOT_MultMMM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* m0, const T_t* m1, unsigned m0cn_m1rn ); + +// same as MultMMM() except second source matrix is transposed prior to the multiply +T_t* cmVOT_MultMMMt(T_t* dbp, unsigned drn, unsigned dcn, const T_t* m0, const T_t* m1, unsigned m0cn_m1rn ); + +//====================================================================================================================== +//) + +//( { label:"Linear algebra" desc:"Miscellaneous linear algebra operations. Determinant, Inversion, Cholesky decompostion. Linear system solver." kw:[vop] } + +// Initialize dbp[dn,dn] as a square symetric positive definite matrix using values +// from a random uniform distribution. This is useful for initializing random +// covariance matrices as used by multivariate Gaussian distributions +// If t is non-NULL it must point to a block of scratch memory of t[dn,dn]. +// If t is NULL then scratch memory is internally allocated and deallocated. +T_t* cmVOT_RandSymPosDef( T_t* dbp, unsigned dn, T_t* t ); + + +// Compute the determinant of any square matrix. +T_t cmVOT_DetM( const T_t* sp, unsigned srn ); + +// Compute the determinant of a diagonal matrix. +T_t cmVOT_DetDiagM( const T_t* sp, unsigned srn); + +// Compute the log determinant of any square matrix. +T_t cmVOT_LogDetM( const T_t* sp, unsigned srn ); + +// Compute the log determinant of a diagonal matrix. +T_t cmVOT_LogDetDiagM( const T_t* sp, unsigned srn); + + +// Compute the inverse of a square matrix. Returns NULL if the matrix is not invertable. +// 'drn' is the dimensionality of the data. +T_t* cmVOT_InvM( T_t* dp, unsigned drn ); + +// Compute the inverse of a diagonal matrix. Returns NULL if the matrix is not invertable. +T_t* cmVOT_InvDiagM( T_t* dp, unsigned drn ); + +// Solve a linear system of the form AX=B where A[an,an] is square. +// Since A is square B must have 'an' rows. +// Result is returned in B. +// Returns a pointer to B on success or NULL on fail. +// NOTE: Both A and B are overwritten by this operation. +T_t* cmVOT_SolveLS( T_t* A, unsigned an, T_t* B, unsigned bcn ); + +// Perform a Cholesky decomposition of the square symetric matrix U[un,un]. +// The factorization has the form: A=U'TU. +// If the factorization is successful A is set to U and a pointer to A is returned. +// Note that the lower triangle of A is not overwritten. See CholZ(). +// If the factorization fails NULL is returned. +T_t* cmVOT_Chol(T_t* A, unsigned an ); + +// Same as Chol() but sets the lower triangle of U to zero. +// This is equivalent ot the Matlab version. +T_t* cmVOT_CholZ(T_t* U, unsigned un ); + +// Calculate the best fit line: b0 + b1*x_i through the points x_i,y_i. +// Set x to NULL if it uses sequential integers [0,1,2,3...] +void cmVOT_Lsq1(const T_t* x, const T_t* y, unsigned n, T_t* b0, T_t* b1 ); + + +//====================================================================================================================== +//) + +//( { label:"Stretch/Shrink" desc:"Stretch or shrink a vector by resampling." kw:[vop] } + +// Return the average value of the contents of sbp[] between two fractional indexes +T_t cmVOT_FracAvg( double bi, double ei, const T_t* sbp, unsigned sn ); + +// Shrinking function - Decrease the size of sbp[] by averaging blocks of values into single values in dbp[] +T_t* cmVOT_DownSampleAvg( T_t* dbp, unsigned dn, const T_t* sbp, unsigned sn ); + +// Stretching function - linear interpolate between points in sbp[] to fill dbp[] ... where dn > sn +T_t* cmVOT_UpSampleInterp( T_t* dbp, unsigned dn, const T_t* sbp, unsigned sn ); + +// Stretch or shrink the sbp[] to fit into dbp[] +T_t* cmVOT_FitToSize( T_t* dbp, unsigned dn, const T_t* sbp, unsigned sn ); + +// Stretch or shrink sV[] to fit into dV[] using a simple linear mapping. +// When stretching (sndn) each dest value is formed by the average of sequential segments +// of sn/dn source elements. Fractional values are used at the beginning +// and end of each segment. +T_t* cmVOT_LinearMap(T_t* dV, unsigned dn, T_t* sV, unsigned sn ); + +//====================================================================================================================== +//) + +//( { label:"Random number generation" desc:"Generate random numbers." kw:[vop] } + +// Generate a vector of uniformly distributed random numbers in the range minVal to maxVal. +T_t* cmVOT_Random( T_t* dbp, unsigned dn, T_t minVal, T_t maxVal ); + +// Generate dn random numbers integers between 0 and wn-1 based on a the relative +// weights in wp[wn]. Note thtat the weights do not have to sum to 1.0. +unsigned* cmVOT_WeightedRandInt( unsigned* dbp, unsigned dn, const T_t* wp, unsigned wn ); + +// Generate a vector of normally distributed univariate random numbers +T_t* cmVOT_RandomGauss( T_t* dbp, unsigned dn, T_t mean, T_t var ); + +// Generate a vector of normally distributed univariate random numbers where each value has been drawn from a +// seperately parameterized Gaussian distribution. meanV[] and varV[] must both contain dn velues. +T_t* cmVOT_RandomGaussV( T_t* dbp, unsigned dn, const T_t* meanV, const T_t* varV ); + +// Generate a matrix of multi-dimensional random values. Each column represents a single vector value and each row contains a dimension. +// meanV[] and varV[] must both contain drn elements where each meanV[i],varV[i] pair parameterize one dimensions Gaussian distribution. +T_t* cmVOT_RandomGaussM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* meanV, const T_t* varV ); +T_t* cmVOT_RandomGaussDiagM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* meanV, const T_t* diagCovarM ); + +// Generate a matrix of multivariate random values drawn from a normal distribution. +// The dimensionality of the values are 'drn'. +// The count of returned values is 'dcn'. +// meanV[drn] and covarM[drn,drn] parameterize the normal distribution. +// The covariance matrix must be symetric and positive definite. +// t[(drn*drn) ] points to scratch memory or is set to NULL if the function should +// allocate the memory internally. +// Based on octave function mvrnd.m. +T_t* cmVOT_RandomGaussNonDiagM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* meanV, const T_t* covarM, T_t* t ); + +// Same as RandomGaussNonDiagM() except requires the upper trianglular +// Cholesky factor of the covar matrix in 'uM'. +T_t* cmVOT_RandomGaussNonDiagM2( T_t* dbp, unsigned drn, unsigned dcn, const T_t* meanV, const T_t* uM ); + + +// Generate a matrix of N*K multi-dimensional data points. +// Where D is the dimensionality of the data. (D == drn). +// K is the number of multi-dimensional PDF's (clusters). +// N is the number of data points to generate per cluster. +// dbp[ D, N*K ] contains the returned data point. +// The first N columns is associated with the cluster 0, +// the next N columns is associated with cluster 1, ... +// meanM[ D, K ] and varM[D,K] parameterize the generating PDF.s for each cluster +T_t* cmVOT_RandomGaussMM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* meanM, const T_t* varM, unsigned K ); + + +// Evaluate the univariate normal distribution defined by 'mean' and 'stdDev'. +T_t* cmVOT_GaussPDF( T_t* dbp, unsigned dn, const T_t* sbp, T_t mean, T_t stdDev ); + +// Evaluate a multivariate normal distribution defined by meanV[D] and covarM[D,D] +// at the data points held in the columns of xM[D,N]. Return the evaluation +// results in the vector yV[N]. D is the dimensionality of the data. N is the number of +// data points to evaluate and values to return in yV[N]. +// Set diagFl to true if covarM is diagonal. +// The function fails and returns false if the covariance matrix is singular. +bool cmVOT_MultVarGaussPDF( T_t* yV, const T_t* xM, const T_t* meanV, const T_t* covarM, unsigned D, unsigned N, bool diagFl ); + +// Same as multVarGaussPDF[] except takes the inverse covar mtx invCovarM[D,D] +// and log determinant of covar mtx. +// Always returns yV[]. +T_t* cmVOT_MultVarGaussPDF2( T_t* yV, const T_t* xM, const T_t* meanV, const T_t* invCovarM, T_t logDet, unsigned D, unsigned N, bool diagFl ); + +// Same as multVarGaussPDF[] except uses a function to obtain the data vectors. +// srcFunc() can filter the data points by returning NULL if the data vector at frmIdx should +// not be evaluated against the PDF. In this case yV[frmIdx] will be set to 0. +T_t* cmVOT_MultVarGaussPDF3( + T_t* yV, + const T_t* (*srcFunc)(void* funcDataPtr, unsigned frmIdx ), + void* funcDataPtr, + const T_t* meanV, + const T_t* invCovarM, + T_t logDet, + unsigned D, + unsigned N, + bool diagFl ); + + +//====================================================================================================================== +//) + + +//( { label:"Signal generators" desc:"Generate periodic signals." kw:[vop] } + +// The following functions all return the phase of the next value. +unsigned cmVOT_SynthSine( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz ); +unsigned cmVOT_SynthCosine( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz ); +unsigned cmVOT_SynthSquare( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz, unsigned otCnt ); +unsigned cmVOT_SynthTriangle( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz, unsigned otCnt ); +unsigned cmVOT_SynthSawtooth( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz, unsigned otCnt ); +unsigned cmVOT_SynthPulseCos( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz, unsigned otCnt ); +unsigned cmVOT_SynthImpulse( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz ); +unsigned cmVOT_SynthPhasor( T_t* dbp, unsigned dn, unsigned phase, double srate, double hz ); + + +// Return value should be passed back via delaySmp on the next call. +T_t cmVOT_SynthPinkNoise( T_t* dbp, unsigned dn, T_t delaySmp ); + +//====================================================================================================================== +//) + +//( { label:"Exponential conversion" desc:"pow() and log() functions." kw:[vop] } + +// Raise dbp[] to the power 'expon' +T_t* cmVOT_PowVS( T_t* dbp, unsigned dn, T_t expon ); +T_t* cmVOT_PowVVS( T_t* dbp, unsigned dn, const T_t* sp, T_t expon ); + +// Take the natural log of all values in sbp[dn]. It is allowable for sbp point to the same array as dbp=. +T_t* cmVOT_LogV( T_t* dbp, unsigned dn, const T_t* sbp ); + +//====================================================================================================================== +//) + +//( { label:"dB Conversions" desc:"Convert vectors between dB,linear and power representations." kw:[vop] } + +// Convert a magnitude (amplitude) spectrum to/from decibels. +// It is allowable for dbp==sbp. +T_t* cmVOT_AmplToDbVV( T_t* dbp, unsigned dn, const T_t* sbp, T_t minDb ); +T_t* cmVOT_DbToAmplVV( T_t* dbp, unsigned dn, const T_t* sbp); + +T_t* cmVOT_PowToDbVV( T_t* dbp, unsigned dn, const T_t* sbp, T_t minDb ); +T_t* cmVOT_DbToPowVV( T_t* dbp, unsigned dn, const T_t* sbp); + +T_t* cmVOT_LinearToDb( T_t* dbp, unsigned dn, const T_t* sp, T_t mult ); +T_t* cmVOT_dBToLinear( T_t* dbp, unsigned dn, const T_t* sp, T_t mult ); +T_t* cmVOT_AmplitudeToDb( T_t* dbp, unsigned dn, const T_t* sp ); +T_t* cmVOT_PowerToDb( T_t* dbp, unsigned dn, const T_t* sp ); +T_t* cmVOT_dBToAmplitude( T_t* dbp, unsigned dn, const T_t* sp ); +T_t* cmVOT_dBToPower( T_t* dbp, unsigned dn, const T_t* sp ); +//====================================================================================================================== +//) + +//( { label:"DSP Windows" desc:"DSP windowing functions." kw:[vop] } + +T_t cmVOT_KaiserBetaFromSidelobeReject( double sidelobeRejectDb ); +T_t cmVOT_KaiserFreqResolutionFactor( double sidelobeRejectDb ); +T_t* cmVOT_Kaiser( T_t* dbp, unsigned dn, double beta ); +T_t* cmVOT_Gaussian(T_t* dbp, unsigned dn, double mean, double variance ); +T_t* cmVOT_Hamming( T_t* dbp, unsigned dn ); +T_t* cmVOT_Hann( T_t* dbp, unsigned dn ); +T_t* cmVOT_Triangle(T_t* dbp, unsigned dn ); + +// The MATLAB equivalent Hamming and Hann windows. +//T_t* cmVOT_HammingMatlab(T_t* dbp, unsigned dn ); +T_t* cmVOT_HannMatlab( T_t* dbp, unsigned dn ); + +// Simulates the MATLAB GaussWin function. Set arg to 2.5 to simulate the default arg +// as used by MATLAB. +T_t* cmVOT_GaussWin( T_t* dbp, unsigned dn, double arg ); +//====================================================================================================================== +//) + +//( { label:"DSP Filters" desc:"DSP filtering functions." kw:[vop] } + +// Direct form II algorithm based on the MATLAB implmentation +// http://www.mathworks.com/access/helpdesk/help/techdoc/ref/filter.html#f83-1015962 +// The only difference between this function and the equivalent MATLAB filter() function +// is that the first feedforward coeff is given as a seperate value. The first b coefficient +// in this function is therefore the same as the second coefficient in the MATLAB function. +// and the first a[] coefficient (which is generally set to 1.0) is skipped. +// Example: +// Matlab: b=[.5 .4 .3] a=[1 .2 .1] +// Equiv: b0 = .5 b=[ .4 .3] a=[ .2 .1]; +// +// y[yn] - output vector +// x[xn] - input vector. xn must be <= yn. if xn < yn then the end of y[] is set to zero. +// b0 - signal scale. This can also be seen as b[0] (which is not included in b[]) +// b[dn] - feedforward coeff's b[1..dn-1] +// a[dn] - feedback coeff's a[1..dn-1] +// d[dn+1] - delay registers - note that this array must be one element longer than the coeff arrays. +// +T_t* cmVOT_Filter( T_t* y, unsigned yn, const T_t* x, unsigned xn, cmReal_t b0, const cmReal_t* b, const cmReal_t* a, cmReal_t* d, unsigned dn ); + +struct cmFilter_str; +//typedef cmRC_t (*cmVOT_FiltExecFunc_t)( struct acFilter_str* f, const T_t* x, unsigned xn, T_t* y, unsigned yn ); +T_t* cmVOT_FilterFilter(struct cmFilter_str* f, cmRC_t (*func)( struct cmFilter_str* f, const T_t* x, unsigned xn, T_t* y, unsigned yn ), const cmReal_t bb[], unsigned bn, const cmReal_t aa[], unsigned an, const T_t* x, unsigned xn, T_t* y, unsigned yn ); + +// Compute the coefficients of a low/high pass FIR filter +// wndV[dn] gives the window function used to truncate the ideal low-pass impulse response. +// Set wndV to NULL to use a unity window. +// See enum { kHighPass_LPSincFl=0x01, kNormalize_LPSincFl=0x02 } in cmVectOps.h +T_t* cmVOT_LP_Sinc(T_t* dp, unsigned dn, const T_t* wndV, double srate, double fcHz, unsigned flags ); + + + +//====================================================================================================================== +//) + +//( { label:"Spectral Masking" desc:"A collection of spectral masking functions." kw:[vop] } + +// Compute a set of filterCnt mel filter masks for wieghting magnitude spectra consisting of binCnt bins. +// The spectrum is divided into bandCnt equal bands in the mel domain +// Each row of the matrix contains the mask for a single filter band consisting of binCnt elements. +// See enum{ kShiftMelFl=0x01, kNormalizeMelFl=0x02 } in cmVectOps.h +// Set kShiftMelFl to shift the mel bands onto the nearest FFT bin. +// Set kNormalizeMelFl to normalize the combined filters for unity gain. +T_t* cmVOT_MelMask( T_t* maskMtx, unsigned bandCnt, unsigned binCnt, double srate, unsigned flags ); + +// Fill binIdxV[bandCnt] and cntV[bandCnt] with a bin to band map. +// binIdx[] contains the first (minimum) bin index for a given band. +// cntV[] contains the count of bins for each band. +// bandCnt is the number of bark bands to return +// The function returns the actual number of bands mapped which will always be <= 23. +unsigned cmVOT_BarkMap(unsigned* binIdxV, unsigned* cntV, unsigned bandCnt, unsigned binCnt, double srate ); + +// Calc a set of triangle fitler masks into each row of maskMtx. +// maskMtx[ bandCnt, binCnt ] - result matrix +// binHz - freq resolution of the output filters. +// stSpread - Semi-tone spread above and below each center frequency (stSpread*2) is the total bandwidth. +// (Only used if lowHzV or uprHzV are NULL) +// lowHz[ bandCnt ] - set of upper frequency limits for each band. +// ctrHz[ bandCnt ] set to the center value in Hz for each band +// uprHz[ bandCnt ] - set of lower frequency limits for each band. +// Note if lowHz[] and uprHz[] are set to NULL then stSpread is used to set the bandwidth of each band. +T_t* cmVOT_TriangleMask(T_t* maskMtx, unsigned bandCnt, unsigned binCnt, const T_t* ctrHzV, T_t binHz, T_t stSpread, const T_t* lowHzV, const T_t* uprHzV ); + +// Calculate a set of Bark band triangle filters into maskMtx. +// Each row of maskMtx contains the filter for one band. +// maskMtx[ bandCnt, binCnt ] +// bandCnt - the number of triangle bankds. If bandCnt is > 24 it will be reduced to 24. +// binCnt - the number of bins in the filters. +// binHz - the width of each bin in Hz. +T_t* cmVOT_BarkMask(T_t* maskMtx, unsigned bandCnt, unsigned binCnt, double binHz ); + +// Terhardt 1979 (Calculating virtual pitch, Hearing Research #1, pp 155-182) +// See enum { kNoTtmFlags=0, kModifiedTtmFl=0x01 } in cmVectOps.h +T_t* cmVOT_TerhardtThresholdMask(T_t* maskV, unsigned binCnt, double srate, unsigned flags); + +//Schroeder et al., 1979, JASA, Optimizing digital speech coders by exploiting masking properties of the human ear +T_t* cmVOT_ShroederSpreadingFunc(T_t* m, unsigned bandCnt, double srate); + +//====================================================================================================================== +//) + +//( { label:"Machine learning" desc:"K-means clustering and Viterbi algorithms." kw:[vop] } + +// Assign each data point to one of k clusters using an expectation-maximization algorithm. +// k gives the number of clusters to identify +// Each column of sp[ srn, scn ] contains a multidimensional data point. +// srn therefore defines the dimensionality of the data. +// Each column of centroidV[ srn, k ] is set to the centroid of each of k clusters. +// classIdxV[ scn ] assigns the index (0 to k-1) of a cluster to each soure data point +// The function returns the number of iterations required for the EM process to converge. +// selIdxV[ scn ] is optional and contains a list of id's assoc'd with each column of sM. +// selKey is a integer value. +// If selIdxV is non-NULL then only columns of sM[] where selIdxV[] == selKey will be clustered. +// All columns of sM[] where the associated column in selIdxV[] do not match will be ignored. +// Set 'initFromCentroidFl' to true if the initial centroids should be taken from centroidM[]. +// otherwise the initial centroids are selected from 'k' random data points in sp[]. +// The distance function distFunc(cV,dV,dN) is called to determine the distance from a +// centroid the centroid 'cV[dN]' to a data point 'dV[dN]'. 'dN' is the dimensionality of the +// feature vector and is therefore equal to 'srn'. +unsigned cmVOT_Kmeans( + unsigned* classIdxV, + T_t* centroidM, + unsigned k, + const T_t* sp, + unsigned srn, + unsigned scn, + const unsigned* selIdxV, + unsigned selKey, + bool initFromCentroidFl, + T_t (*distFunc)( void* userPtr, const T_t* cV, const T_t* dV, unsigned dN ), + void* userDistPtr ); + +// 'srcFunc() should return NULL if the data point located at 'frmIdx' should not be included in the clustering. +// Clustering is considered to be complete after 'maxIterCnt' iterations or when +// 'deltaStopCnt' or fewer data points change class on a single iteration +unsigned cmVOT_Kmeans2( + unsigned* classIdxV, // classIdxV[scn] - data point class assignments + T_t* centroidM, // centroidM[srn,K] - cluster centroids + unsigned K, // count of clusters + const T_t* (*srcFunc)(void* userPtr, unsigned frmIdx ), + unsigned srn, // dimensionality of each data point + unsigned scn, // count of data points + void* userSrcPtr, // callback data for srcFunc + T_t (*distFunc)( void* userPtr, const T_t* cV, const T_t* dV, unsigned dN ), + void* userDistPtr, // arg. to distFunc() + int iterCnt, // max. number of iterations (-1 to ignore) + int deltaStopCnt); // if less than deltaStopCnt data points change classes on a given iteration then convergence occurs. + +// Determine the most likely state sequece stateV[timeN] given a +// transition matrix a[stateN,stateN], +// observation probability matrix b[stateN,timeN] and +// initial state probability vector phi[stateN]. +// a[i,j] is the probability of transitioning from state i to state j. +// b[i,t] is the probability of state i emitting the obj t. +void cmVOT_DiscreteViterbi(unsigned* stateV, unsigned timeN, unsigned stateN, const T_t* phi, const T_t* a, const T_t* b ); + + +//====================================================================================================================== +//) + +//( { label:"Graphics" desc:"Graphics related algorithms." kw:[vop] } + +// Generate the set of coordinates which describe a circle with a center at x,y. +// dbp[dn,2] must contain 2*dn elements. The first column holds the x coord and and the second holds the y coord. +T_t* cmVOT_CircleCoords( T_t* dbp, unsigned dn, T_t x, T_t y, T_t varX, T_t varY ); + +// Clip the line defined by x0,y0 to x1,y1 into the rect defined by xMin,yMin xMax,yMax. +bool cmVOT_ClipLine( T_t* x0, T_t* y0, T_t* x1, T_t* y1, T_t xMin, T_t yMin, T_t xMax, T_t yMax ); + +// Return true if the line defined by x0,y0 to x1,y1 intersects with +// the rectangle formed by xMin,yMin - xMax,yMax +bool cmVOT_IsLineInRect( T_t x0, T_t y0, T_t x1, T_t y1, T_t xMin, T_t yMin, T_t xMax, T_t yMax ); + + +// Return the perpendicular distance from the line formed by x0,y0 and x1,y1 +// and the point px,py +T_t cmVOT_PtToLineDistance( T_t x0, T_t y0, T_t x1, T_t y1, T_t px, T_t py); + +//====================================================================================================================== +//) + +//( { label:"Miscellaneous DSP" desc:"Common DSP algorithms." kw:[vop] } + +// Compute the complex transient detection function from successive spectral frames. +// The spectral magntidue mag0V precedes mag1V and the phase (radians) spectrum phs0V precedes the phs1V which precedes phs2V. +// binCnt gives the length of each of the spectral vectors. +T_t cmVOT_ComplexDetect(const T_t* mag0V, const T_t* mag1V, const T_t* phs0V, const T_t* phs1V, const T_t* phs2V, unsigned binCnt ); + +// Compute a set of DCT-II coefficients. Result dp[ coeffCnt, filtCnt ] +T_t* cmVOT_DctMatrix( T_t* dp, unsigned coeffCnt, unsigned filtCnt ); + + +// Set the indexes of local peaks greater than threshold in dbp[]. +// Returns the number of peaks in dbp[] +// The maximum number of peaks from n source values is max(0,floor((n-1)/2)). +// Note that peaks will never be found at index 0 or index sn-1. +unsigned cmVOT_PeakIndexes( unsigned* dbp, unsigned dn, const T_t* sbp, unsigned sn, T_t threshold ); + +// Return the index of the bin containing v otherwise return kInvalidIdx if v is below sbp[0] or above sbp[ n-1 ] +// The bin limits are contained in sbp[]. +// The value in spb[] are therefore expected to be in increasing order. +// The value returned will be in the range 0:sn-1. +unsigned cmVOT_BinIndex( const T_t* sbp, unsigned sn, T_t v ); + + +// Given the points x0[xy0N],y0[xy0N] fill y1[i] with the interpolated value of y0[] at +// x1[i]. Note that x0[] and x1[] must be increasing monotonic. +// This function is similar to the octave interp1() function. +void cmVOT_Interp1(T_t* y1, const T_t* x1, unsigned xy1N, const T_t* x0, const T_t* y0, unsigned xy0N ); + +//====================================================================================================================== +//) + + +//( { label:"Matrix ops" desc:"Common 2D matrix operations and accessors." kw:[vop] } + +// 2D matrix accessors +T_t* cmVOT_Col( T_t* m, unsigned ci, unsigned rn, unsigned cn ); +T_t* cmVOT_Row( T_t* m, unsigned ri, unsigned rn, unsigned cn ); +T_t* cmVOT_ElePtr( T_t* m, unsigned ri, unsigned ci, unsigned rn, unsigned cn ); +T_t cmVOT_Ele( T_t* m, unsigned ri, unsigned ci, unsigned rn, unsigned cn ); +void cmVOT_Set( T_t* m, unsigned ri, unsigned ci, unsigned rn, unsigned cn, T_t v ); + +const T_t* cmVOT_CCol( const T_t* m, unsigned ci, unsigned rn, unsigned cn ); +const T_t* cmVOT_CRow( const T_t* m, unsigned ri, unsigned rn, unsigned cn ); +const T_t* cmVOT_CElePtr( const T_t* m, unsigned ri, unsigned ci, unsigned rn, unsigned cn ); +T_t cmVOT_CEle( const T_t* m, unsigned ri, unsigned ci, unsigned rn, unsigned cn ); + + +// Set only the diagonal of a square mtx to sbp. +T_t* cmVOT_Diag( T_t* dbp, unsigned n, const T_t* sbp ); + +// Set the diagonal of a square mtx to db to sbp and set all other values to zero. +T_t* cmVOT_DiagZ( T_t* dbp, unsigned n, const T_t* sbp ); + +// Create an identity matrix (only sets 1's not zeros). +T_t* cmVOT_Identity( T_t* dbp, unsigned rn, unsigned cn ); + +// Zero the matrix and then fill it as an identity matrix. +T_t* cmVOT_IdentityZ( T_t* dbp, unsigned rn, unsigned cn ); + +// Transpose the matrix sbp[srn,scn] into dbp[scn,srn] +T_t* cmVOT_Transpose( T_t* dbp, const T_t* sbp, unsigned srn, unsigned scn ); + +//====================================================================================================================== +//) + + +//( { label:"Fill,move,copy" desc:"Basic data movement and initialization." kw:[vop] } + +// Fill a vector with a value. If value is 0 then the function is accellerated via memset(). +T_t* cmVOT_Fill( T_t* dbp, unsigned dn, T_t value ); + +// Fill a vector with zeros +T_t* cmVOT_Zero( T_t* dbp, unsigned dn ); + +// Analogous to memmove() +T_t* cmVOT_Move( T_t* dbp, unsigned dn, const T_t* sp ); + +// Fill the vector from various sources +T_t* cmVOT_Copy( T_t* dbp, unsigned dn, const T_t* sp ); +T_t* cmVOT_CopyN( T_t* dbp, unsigned dn, unsigned d_stride, const T_t* sp, unsigned s_stride ); +T_t* cmVOT_CopyU( T_t* dbp, unsigned dn, const unsigned* sp ); +T_t* cmVOT_CopyI( T_t* dbp, unsigned dn, const int* sp ); +T_t* cmVOT_CopyF( T_t* dbp, unsigned dn, const float* sp ); +T_t* cmVOT_CopyD( T_t* dbp, unsigned dn, const double* sp ); +T_t* cmVOT_CopyS( T_t* dbp, unsigned dn, const cmSample_t* sp ); +T_t* cmVOT_CopyR( T_t* dbp, unsigned dn, const cmReal_t* sp ); + +// Fill the the destination vector from a source vector where the source vector contains +// srcStride interleaved elements to be ignored. +T_t* cmVOT_CopyStride( T_t* dbp, unsigned dn, const T_t* sp, unsigned srcStride ); + + +//====================================================================================================================== +//) + +//( { label:"Shrink/Expand/Replace" desc:"Change the size of a vector." kw:[vop] } + + +// Shrink the elemetns of dbp[dn] by copying all elements past t+tn to t. +// This operation results in overwriting the elements in the range t[tn]. +// t[tn] must be entirely inside dbp[dn]. +T_t* cmVOT_Shrink( T_t* dbp, unsigned dn, const T_t* t, unsigned tn ); + +// Expand dbp[[dn] by shifting all elements past t to t+tn. +// This produces a set of empty elements in t[tn]. +// t must be inside or at the end of dbp[dn]. +// This results in a reallocation of dbp[]. Be sure to call cmMemFree(dbp) +// to release the returned pointer. +T_t* cmVOT_Expand( T_t* dbp, unsigned dn, const T_t* t, unsigned tn ); + +// Replace the elements t[tn] with the elements in u[un]. +// t must be inside or at the end of dbp[dn]. +// This operation may result in a reallocation of dbp[]. Be sure to call cmMemFree(dbp) +// to release the returned pointer. +// IF dbp==NULL and tn==0 then the dbp[un] is allocated and returned +// with the contents of u[un]. +T_t* cmVOT_Replace(T_t* dbp, unsigned* dn, const T_t* t, unsigned tn, const T_t* u, unsigned un ); + +//====================================================================================================================== +//) + + + +//( { label:"Rotate/Shift/Flip/Sequence" desc:"Modify/generate the vector sequence." kw:[vop] } + +// Assuming a row vector positive shiftCnt rotates right, negative shiftCnt rotates left. +T_t* cmVOT_Rotate( T_t* dbp, unsigned dn, int shiftCnt ); + +// Equivalent to Matlab circshift(). +T_t* cmVOT_RotateM( T_t* dbp, unsigned drn, unsigned dcn, const T_t* sbp, int rShift, int cShift ); + +// Assuming a row vector positive shiftCnt shifts right, negative shiftCnt shifts left. +T_t* cmVOT_Shift( T_t* dbp, unsigned dn, int shiftCnt, T_t fill ); + +// Reverse the contents of the vector. +T_t* cmVOT_Flip( T_t* dbp, unsigned dn); + +// Fill dbp[] with a sequence of values. Returns next value. +T_t cmVOT_Seq( T_t* dbp, unsigned dn, T_t beg, T_t incr ); + + + + +//====================================================================================================================== +//) + +//( { label:"Arithmetic" desc:"Add,Sub,Mult,Divde" kw:[vop] } + +T_t* cmVOT_SubVS( T_t* dp, unsigned dn, T_t v ); +T_t* cmVOT_SubVV( T_t* dp, unsigned dn, const T_t* v ); +T_t* cmVOT_SubVVS( T_t* dp, unsigned dn, const T_t* v, T_t s ); +T_t* cmVOT_SubVVNN(T_t* dp, unsigned dn, unsigned dnn, const T_t* sp, unsigned snn ); +T_t* cmVOT_SubVVV( T_t* dp, unsigned dn, const T_t* sb0p, const T_t* sb1p ); +T_t* cmVOT_SubVSV( T_t* dp, unsigned dn, const T_t s0, const T_t* sb1p ); + +T_t* cmVOT_AddVS( T_t* dp, unsigned dn, T_t v ); +T_t* cmVOT_AddVV( T_t* dp, unsigned dn, const T_t* v ); +T_t* cmVOT_AddVVS( T_t* dp, unsigned dn, const T_t* v, T_t s ); +T_t* cmVOT_AddVVNN(T_t* dp, unsigned dn, unsigned dnn, const T_t* sp, unsigned snn ); +T_t* cmVOT_AddVVV( T_t* dp, unsigned dn, const T_t* sb0p, const T_t* sb1p ); + +T_t* cmVOT_MultVVV( T_t* dbp, unsigned dn, const T_t* sb0p, const T_t* sb1p ); +T_t* cmVOT_MultVV( T_t* dbp, unsigned dn, const T_t* sbp ); +T_t* cmVOT_MultVVNN(T_t* dp, unsigned dn, unsigned dnn, const T_t* sp, unsigned snn ); +T_t* cmVOT_MultVS( T_t* dbp, unsigned dn, T_t s ); +T_t* cmVOT_MultVVS( T_t* dbp, unsigned dn, const T_t* sbp, T_t s ); +T_t* cmVOT_MultVaVS( T_t* dbp, unsigned dn, const T_t* sbp, T_t s ); +T_t* cmVOT_MultSumVVS(T_t* dbp, unsigned dn, const T_t* sbp, T_t s ); + +T_t* cmVOT_DivVVS( T_t* dbp, unsigned dn, const T_t* sb0p, T_t sb1 ); +T_t* cmVOT_DivVVV( T_t* dbp, unsigned dn, const T_t* sb0p, const T_t* sb1p ); +T_t* cmVOT_DivVV( T_t* dbp, unsigned dn, const T_t* sb0p ); +T_t* cmVOT_DivVVNN(T_t* dp, unsigned dn, unsigned dnn, const T_t* sp, unsigned snn ); +T_t* cmVOT_DivVS( T_t* dbp, unsigned dn, T_t s ); +T_t* cmVOT_DivVSV( T_t* dp, unsigned dn, const T_t s0, const T_t* sb1p ); + +// Set dest to 0 if denominator is 0. +T_t* cmVOT_DivVVVZ( T_t* dbp, unsigned dn, const T_t* sb0p, const T_t* sb1p ); +T_t* cmVOT_DivVVZ( T_t* dbp, unsigned dn, const T_t* sb0p ); + +// Divide columns of dp[:,i] by each value in the source vector sp[i]. +T_t* cmVOT_DivMS( T_t* dp, unsigned drn, unsigned dcn, const T_t* sp ); + +//====================================================================================================================== +//) + +//( { label:"Sum vectors" desc:"Operations which take sum vector elements." kw:[vop] } + +T_t cmVOT_Sum( const T_t* sp, unsigned sn ); +T_t cmVOT_SumN( const T_t* sp, unsigned sn, unsigned stride ); + +// Sum the columns of sp[srn,scn] into dp[scn]. +// dp[] is zeroed prior to computing the sum. +T_t* cmVOT_SumM( const T_t* sp, unsigned srn, unsigned scn, T_t* dp ); + +// Sum the rows of sp[srn,scn] into dp[srn] +// dp[] is zeroed prior to computing the sum. +T_t* cmVOT_SumMN( const T_t* sp, unsigned srn, unsigned scn, T_t* dp ); + +//====================================================================================================================== +//) + + +//( { label:"Min/max/median/mode" desc:"Simple descriptive statistics." kw:[vop] } + +T_t cmVOT_Median( const T_t* sp, unsigned sn ); +unsigned cmVOT_MinIndex( const T_t* sp, unsigned sn, unsigned stride ); +unsigned cmVOT_MaxIndex( const T_t* sp, unsigned sn, unsigned stride ); +T_t cmVOT_Min( const T_t* sp, unsigned sn, unsigned stride ); +T_t cmVOT_Max( const T_t* sp, unsigned sn, unsigned stride ); + +T_t* cmVOT_MinVV( T_t* dp, unsigned dn, const T_t* sp ); +T_t* cmVOT_MaxVV( T_t* dp, unsigned dn, const T_t* sp ); + + +// Return index of max/min value into dp[scn] of each column of sp[srn,scn] +unsigned* cmVOT_MinIndexM( unsigned* dp, const T_t* sp, unsigned srn, unsigned scn ); +unsigned* cmVOT_MaxIndexM( unsigned* dp, const T_t* sp, unsigned srn, unsigned scn ); + +// Return the most frequently occuring element in sp. +T_t cmVOT_Mode( const T_t* sp, unsigned sn ); + +//====================================================================================================================== +//) + +//( { label:"Compare/Find" desc:"Compare, find, replace and count elements in a vector." kw:[vop] } + +// Return true if s0p[sn] is equal to s1p[sn] +bool cmVOT_IsEqual( const T_t* s0p, const T_t* s1p, unsigned sn ); + +// Return true if all elements of s0p[sn] are within 'eps' of s1p[sn]. +// This function is based on cmMath.h:cmIsCloseX() +bool cmVOT_IsClose( const T_t* s0p, const T_t* s1p, unsigned sn, double eps ); + +// Replace all values <= lteKeyVal with replaceVal. sp==dp is legal. +T_t* cmVOT_ReplaceLte( T_t* dp, unsigned dn, const T_t* sp, T_t lteKeyVal, T_t replaceVal ); + +// Return the index of 'key' in sp[sn] or cmInvalidIdx if 'key' does not exist. +unsigned cmVOT_Find( const T_t* sp, unsigned sn, T_t key ); + +// Count the number of times 'key' occurs in sp[sn]. +unsigned cmVOT_Count(const T_t* sp, unsigned sn, T_t key ); + +//====================================================================================================================== +//) + + + +//( { label:"Absolute value" desc:"Absolute value and signal rectification." kw:[vop] } + +T_t* cmVOT_Abs( T_t* dbp, unsigned dn ); + +// Half wave rectify the source vector. +// dbp[] = sbp<0 .* sbp +// Overlapping the source and dest is allowable as long as dbp <= sbp. +T_t* cmVOT_HalfWaveRectify(T_t* dbp, unsigned dn, const T_t* sp ); + +//====================================================================================================================== +//) + + +//( { label:"Filter" desc:"Apply filtering to a vector taking into account vector begin/end conditions." kw:[vop] } + +// Apply a median or other filter of order wndN to xV[xN] and store the result in yV[xN]. +// When the window goes off either side of the vector the window is shortened. +// This algorithm produces the same result as the fn_thresh function in MATLAB fv codebase. +void cmVOT_FnThresh( const T_t* xV, unsigned xN, unsigned wndN, T_t* yV, unsigned yStride, T_t (*fnPtr)(const T_t*, unsigned) ); + + +// Apply a median filter of order wndN to xV[xN] and store the result in yV[xN]. +// When the window goes off either side of the vector the missing elements are considered +// to be 0. +// This algorithm produces the same result as the MATLAB medfilt1() function. +void cmVOT_MedianFilt( const T_t* xV, unsigned xN, unsigned wndN, T_t* yV, unsigned yStride ); +//====================================================================================================================== +//) + + +//( { label:"Edit distance" desc:"Calculate the Levenshtein edit distance between vectors." kw:[vop] } + +// Allocate and initialize a matrix for use by LevEditDist(). +// This matrix can be released with a call to cmMemFree(). +unsigned* cmVOT_LevEditDistAllocMtx(unsigned mtxMaxN); + +// Return the Levenshtein edit distance between two vectors. +// m must point to a matrix pre-allocated by cmVOT_InitiLevEditDistMtx(maxN). +double cmVOT_LevEditDist(unsigned mtxMaxN, unsigned* m, const T_t* s0, int n0, const T_t* s1, int n1, unsigned maxN ); + +// Return the Levenshtein edit distance between two vectors. +// Edit distance with a max cost threshold. This version of the algorithm +// will run faster than LevEditDist() because it will stop execution as soon +// as the distance exceeds 'maxCost'. +// 'maxCost' must be between 0.0 and 1.0 or it is forced into this range. +// The maximum distance returned will be 'maxCost'. +// m must point to a matrix pre-allocated by cmVOT_InitiLevEditDistMtx(maxN). +double cmVOT_LevEditDistWithCostThresh( int mtxMaxN, unsigned* m, const T_t* s0, int n0, const T_t* s1, int n1, double maxCost, unsigned maxN ); + +//====================================================================================================================== +//) + + diff --git a/src/cmXml.h b/src/cmXml.h index 1aeffdd..08e7836 100644 --- a/src/cmXml.h +++ b/src/cmXml.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"XML file reader." kw[file] } + enum { kOkXmlRC = cmOkRC, @@ -101,6 +103,8 @@ extern "C" { cmXmlRC_t cmXmlTest( cmCtx_t* ctx, const cmChar_t* fn ); + + //) #ifdef __cpluspus } diff --git a/src/dsp/cmDspBuiltIn.h b/src/dsp/cmDspBuiltIn.h index 0e96869..dabb6c0 100644 --- a/src/dsp/cmDspBuiltIn.h +++ b/src/dsp/cmDspBuiltIn.h @@ -6,9 +6,13 @@ extern "C" { #endif + + //( { file_desc:"Dataflow built-in process interface." kw:[snap] } + // Returns NULL if index is outside of valid range. cmDspClassConsFunc_t cmDspClassGetBuiltIn( unsigned index ); + //) #ifdef __cplusplus diff --git a/src/dsp/cmDspCtx.h b/src/dsp/cmDspCtx.h index 45e618c..5992cfa 100644 --- a/src/dsp/cmDspCtx.h +++ b/src/dsp/cmDspCtx.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"Dataflow global context interface." kw:[snap] } + typedef cmHandle_t cmDspSysH_t; typedef cmHandle_t cmDspStoreH_t; @@ -34,6 +36,8 @@ extern "C" { unsigned execDurUsecs; } cmDspCtx_t; + //) + #ifdef __cplusplus } #endif diff --git a/src/dsp/cmDspFx.h b/src/dsp/cmDspFx.h index c5af6bb..08edbbf 100644 --- a/src/dsp/cmDspFx.h +++ b/src/dsp/cmDspFx.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"Large collection of real-time audio processing dataflow class descriptions originally developed for 'fluxo'." kw:[snap fluxo] } + struct cmDspClass_str* cmDelayClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmPShiftClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmLoopRecdClassCons( cmDspCtx_t* ctx ); @@ -43,6 +45,8 @@ extern "C" { struct cmDspClass_str* cmBcastSymClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmSegLineClassCons( cmDspCtx_t* ctx ); + //) + #ifdef __cplusplus } #endif diff --git a/src/dsp/cmDspPgm.h b/src/dsp/cmDspPgm.h index 5d52a17..5e0ed70 100644 --- a/src/dsp/cmDspPgm.h +++ b/src/dsp/cmDspPgm.h @@ -5,6 +5,8 @@ extern "C" { #endif + //( { file_desc:"Dataflow program instance interface." kw:[snap] } + typedef cmDspRC_t (*cmDspPgmFunc_t)( cmDspSysH_t h, void** userPtrPtr ); typedef struct @@ -20,7 +22,7 @@ extern "C" { _cmDspSysPgm_t* _cmDspSysPgmArrayBase(); - + //) #ifdef __cplusplus } diff --git a/src/dsp/cmDspPgmKr.h b/src/dsp/cmDspPgmKr.h index b0cc52e..f19643b 100644 --- a/src/dsp/cmDspPgmKr.h +++ b/src/dsp/cmDspPgmKr.h @@ -5,11 +5,15 @@ extern "C" { #endif + //( { file_desc:"Dataflow pgm interfaces for 'GUTIM'." kw:[gutim snap] } + cmDspRC_t _cmDspSysPgm_TimeLine( cmDspSysH_t h, void** userPtrPtr ); cmDspRC_t _cmDspSysPgm_TimeLineLite( cmDspSysH_t h, void** userPtrPtr ); cmDspRC_t _cmDspSysPgm_TimeLineLiteAf( cmDspSysH_t h, void** userPtrPtr ); cmDspRC_t _cmDspSysPgm_Tksb(cmDspSysH_t h, void** userPtrPtr ); cmDspRC_t _cmDspSysPgm_TksbLite(cmDspSysH_t h, void** userPtrPtr ); + + //) #ifdef __cplusplus } diff --git a/src/dsp/cmDspPgmKrChain.h b/src/dsp/cmDspPgmKrChain.h index a0bb54c..36257bf 100644 --- a/src/dsp/cmDspPgmKrChain.h +++ b/src/dsp/cmDspPgmKrChain.h @@ -6,6 +6,8 @@ extern "C" { #endif + //( { file_desc:"Signal processing chain implementation for 'GUTIM'." kw:[snap gutim] } + typedef struct { const cmChar_t* tlFn; @@ -44,6 +46,7 @@ void _cmDspSys_TlXformChain( unsigned ach, unsigned mch ); + //) #ifdef __cplusplus } diff --git a/src/dsp/cmDspPgmPPMain.h b/src/dsp/cmDspPgmPPMain.h index 39896d1..87e33e7 100644 --- a/src/dsp/cmDspPgmPPMain.h +++ b/src/dsp/cmDspPgmPPMain.h @@ -1,6 +1,7 @@ #ifndef cmDspPgmPPMain_h #define cmDspPgmPPMain_h +//( { file_desc:"'fluxo' implementation header." kw:[fluxo] } cmDspInst_t* _cmDspSys_PresetMgmt( cmDspSysH_t h, const cmChar_t* preLbl, unsigned presetGroupSymId ); @@ -44,6 +45,8 @@ const _cmDspPP_CircDesc_t* _cmDspPP_CircuitDesc( unsigned idx ); cmDspRC_t _cmDspPP_CircuitSwitchAlloc( cmDspSysH_t h, _cmDspPP_Ctx_t* ctx, cmDspPP_CircuitSwitch_t* p, cmDspInst_t* reset, cmDspInst_t** csel, cmDspInst_t** ain, cmDspInst_t** ef ); cmDspRC_t _cmDspPP_CircuitSwitchFree( cmDspSysH_t h, cmDspPP_CircuitSwitch_t* p); +//) + #ifdef __cplusplus extern "C" { #endif diff --git a/src/dsp/cmDspUi.h b/src/dsp/cmDspUi.h index 76fc5ca..8caff49 100644 --- a/src/dsp/cmDspUi.h +++ b/src/dsp/cmDspUi.h @@ -8,7 +8,9 @@ extern "C" { #endif + //( { file_desc:"Dataflow UI interfaces." kw:[snap] } + //) #ifdef __cplusplus diff --git a/src/vop/cmVectOpsDoc.h b/src/vop/cmVectOpsDoc.h index 7c0c9a7..6e4b109 100644 --- a/src/vop/cmVectOpsDoc.h +++ b/src/vop/cmVectOpsDoc.h @@ -5,8 +5,9 @@ // is generated using the gcc preprocessor. // switches: -E : Stop after preprocess // -C : Do not strip comments. -// -P : Do not generate line markers -// gcc -E -C -P -o cmVectOpsDocOut.h cmVectOpsDoc.h +// -P : Do not generate line markers +// -traditional-cpp : preserve white space +// gcc -E -C -P -traditional-cpp -o cmVectOpsDocOut.h cmVectOpsDoc.h #include "cmVectOpsTemplateUndef.h" @@ -17,11 +18,9 @@ #define VECT_OP_MIN FLT_MIN #define VECT_OP_LAP_FUNC(F) s##F #define VECT_OP_BLAS_FUNC(F) cblas_s##F - -//{ -//[ +//end_cut +//( { file_desc:"Math vector operations." kw:[vop math] } +//) #include "cmVectOpsTemplateHdr.h" #include "cmVectOpsRIHdr.h" -//] -//} diff --git a/src/vop/cmVectOpsRICode.h b/src/vop/cmVectOpsRICode.h index 0f1d438..1bf7b55 100644 --- a/src/vop/cmVectOpsRICode.h +++ b/src/vop/cmVectOpsRICode.h @@ -46,6 +46,57 @@ VECT_OP_TYPE VECT_OP_FUNC(CEle)( const VECT_OP_TYPE* m, unsigned ri, unsigned ci { return *VECT_OP_FUNC(CElePtr)(m,ri,ci,rn,cn); } +VECT_OP_TYPE* VECT_OP_FUNC(Diag)( VECT_OP_TYPE* dbp, unsigned n, const VECT_OP_TYPE* sbp ) +{ + unsigned i,j; + for(i=0,j=0; imx ) + { + mi = i; + mx = cmAbs(dp[i]); + } + + VECT_OP_FUNC(MultVS)(dp,dn,fact/mx); + + return mi; + +} + + + VECT_OP_TYPE VECT_OP_FUNC(Mean)( const VECT_OP_TYPE* bp, unsigned n ) { return VECT_OP_FUNC(Sum)(bp,n)/n; } @@ -312,52 +357,6 @@ VECT_OP_TYPE* VECT_OP_FUNC(VarianceM)(VECT_OP_TYPE* dp, const VECT_OP_TYPE* sp return dp; } -unsigned VECT_OP_FUNC(NormToMax)( VECT_OP_TYPE* dp, unsigned dn ) -{ - unsigned i = VECT_OP_FUNC(MaxIndex)(dp,dn,1); - - if( i != cmInvalidIdx ) - { - VECT_OP_TYPE v = dp[i]; - VECT_OP_FUNC(DivVS)(dp,dn,v); - } - - return i; -} - -unsigned VECT_OP_FUNC(NormToAbsMax)( VECT_OP_TYPE* dp, unsigned dn, VECT_OP_TYPE fact ) -{ - if( dn == 0 ) - return cmInvalidIdx; - - unsigned i = 0; - unsigned mi = 0; - VECT_OP_TYPE mx = cmAbs(dp[0]); - - for(i=1; imx ) - { - mi = i; - mx = cmAbs(dp[i]); - } - - VECT_OP_FUNC(MultVS)(dp,dn,fact/mx); - - return mi; - -} - - -VECT_OP_TYPE VECT_OP_FUNC(AlphaNorm)(const VECT_OP_TYPE* sp, unsigned sn, VECT_OP_TYPE alpha ) -{ - double sum = 0; - const VECT_OP_TYPE* bp = sp; - const VECT_OP_TYPE* ep = sp + sn; - while( bp < ep ) - sum += pow(fabs(*bp++),alpha); - - return (VECT_OP_TYPE)pow(sum/sn,1.0/alpha); -} void VECT_OP_FUNC(GaussCovariance)(VECT_OP_TYPE* yM, unsigned D, const VECT_OP_TYPE* xM, unsigned xN, const VECT_OP_TYPE* uV, const unsigned* selIdxV, unsigned selKey ) { @@ -468,14 +467,6 @@ void VECT_OP_FUNC(GaussCovariance2)(VECT_OP_TYPE* yM, unsigned D, const VECT_OP } -bool VECT_OP_FUNC(Equal)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ) -{ - const VECT_OP_TYPE* ep = s0p + sn; - while( s0p < ep ) - if( *s0p++ != *s1p++ ) - return false; - return true; -} bool VECT_OP_FUNC(IsNormal)( const VECT_OP_TYPE* sp, unsigned sn ) { @@ -584,6 +575,19 @@ VECT_OP_TYPE* VECT_OP_FUNC(RmsV)( VECT_OP_TYPE* dp, unsigned dn, const VECT_OP_T VECT_OP_TYPE VECT_OP_FUNC(EuclidNorm)( const VECT_OP_TYPE* sp, unsigned sn ) { return (VECT_OP_TYPE)sqrt( VECT_OP_FUNC(MultSumVV)(sp,sp,sn)); } + +VECT_OP_TYPE VECT_OP_FUNC(AlphaNorm)(const VECT_OP_TYPE* sp, unsigned sn, VECT_OP_TYPE alpha ) +{ + double sum = 0; + const VECT_OP_TYPE* bp = sp; + const VECT_OP_TYPE* ep = sp + sn; + while( bp < ep ) + sum += pow(fabs(*bp++),alpha); + + return (VECT_OP_TYPE)pow(sum/sn,1.0/alpha); +} + + /* From:http://www.ee.ic.ac.uk/hp/staff/dmb/voicebox/doc/voicebox/distitpf.html [nf1,p2]=size(pf1); @@ -1150,47 +1154,6 @@ VECT_OP_TYPE* VECT_OP_FUNC(LogV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_ return dbp; } -VECT_OP_TYPE* VECT_OP_FUNC(AmplToDbVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE minDb ) -{ - VECT_OP_TYPE minVal = pow(10.0,minDb/20.0); - VECT_OP_TYPE* dp = dbp; - VECT_OP_TYPE* ep = dp + dn; - - for(; dp M_PI) - dev_rads -= 2*M_PI; - - while( dev_rads < -M_PI) - dev_rads += 2*M_PI; - - // convert into rect coord's - double m1r = *mag1V++; - double m0r = *mag0V * cos(dev_rads); - double m0i = *mag0V++ * sin(dev_rads); - - // calc the combined amplitude and phase deviation - // sum += hypot( m1 - (m0 * e^(-1*dev_rads))); - - sum += hypot( m1r-m0r, -m0i ); - - } - - return (VECT_OP_TYPE)sum; -} VECT_OP_TYPE* VECT_OP_FUNC(MelMask)( VECT_OP_TYPE* maskMtx, unsigned filterCnt, unsigned binCnt, double srate, unsigned flags ) { @@ -2614,68 +2728,6 @@ VECT_OP_TYPE* VECT_OP_FUNC(ShroederSpreadingFunc)(VECT_OP_TYPE* m, unsigned band return m; } - -VECT_OP_TYPE* VECT_OP_FUNC(DctMatrix)( VECT_OP_TYPE* dp, unsigned coeffCnt, unsigned filtCnt ) -{ - VECT_OP_TYPE* dbp = dp; - - double c0 = 1.0/sqrt(filtCnt/2); // row 1-coeffCnt factor - double c1 = c0 * sqrt(2)/2; // row 0 factor - - unsigned i,j; - - // for each column - for(i=0; i *s2p) && (*s1p >= threshold) ) - { - *dbp++ = s1p - sbp; - s0p = s2p++; - s1p = s2p++; - ++pkCnt; - } - else - { - s0p = s1p; - s1p = s2p++; - } - } - - return pkCnt; -} - -unsigned VECT_OP_FUNC(BinIndex)( const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE v ) -{ - const VECT_OP_TYPE* sep = sbp + sn; - const VECT_OP_TYPE* bp = sbp; - sep--; - for(; sbp < sep; ++sbp ) - if( *sbp <= v && v < *(sbp+1) ) - return sbp - bp; - - return cmInvalidIdx; -} - - - unsigned VECT_OP_FUNC(Kmeans)( unsigned* classIdxV, // classIdxV[scn] - data point class assignments VECT_OP_TYPE* centroidM, // centroidM[srn,K] - cluster centroids @@ -2913,136 +2965,6 @@ unsigned VECT_OP_FUNC(Kmeans2)( return iterCnt; } - -VECT_OP_TYPE* VECT_OP_FUNC(GaussPDF)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE mean, VECT_OP_TYPE stdDev ) -{ - VECT_OP_TYPE* rp = dbp; - const VECT_OP_TYPE* dep = dbp + dn; - VECT_OP_TYPE var = stdDev * stdDev; - VECT_OP_TYPE fact0 = 1.0/sqrt(2*M_PI*var); - VECT_OP_TYPE fact1 = 2.0 * var; - - for(; dbp < dep; ++sbp ) - *dbp++ = fact0 * exp( -((*sbp-mean)*(*sbp-mean))/ fact1 ); - - return rp; -} - -/// Evaluate a multivariate normal distribution defined by meanV[D] and covarM[D,D] -/// at the data points held in the columns of xM[D,N]. Return the evaluation -/// results in the vector yV[N]. -bool VECT_OP_FUNC(MultVarGaussPDF)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* covarM, unsigned D, unsigned N, bool diagFl ) -{ - VECT_OP_TYPE det0; - - // calc the determinant of the covariance matrix - if( diagFl ) - // kpl 1/16/11 det0 = VECT_OP_FUNC(LogDetDiagM)(covarM,D); - det0 = VECT_OP_FUNC(DetDiagM)(covarM,D); - else - // kpl 1/16/11 det0 = VECT_OP_FUNC(LogDetM)(covarM,D); - det0 = VECT_OP_FUNC(DetM)(covarM,D); - - assert(det0 != 0 ); - - if( det0 == 0 ) - return false; - - // calc the inverse of the covariance matrix - VECT_OP_TYPE icM[D*D]; - VECT_OP_FUNC(Copy)(icM,D*D,covarM); - - VECT_OP_TYPE* r; - if( diagFl ) - r = VECT_OP_FUNC(InvDiagM)(icM,D); - else - r = VECT_OP_FUNC(InvM)(icM,D); - - if( r == NULL ) - return false; - - VECT_OP_FUNC(MultVarGaussPDF2)( yV, xM, meanV, icM, det0, D, N, diagFl ); - - return true; -} - -VECT_OP_TYPE* VECT_OP_FUNC(MultVarGaussPDF2)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* icM, VECT_OP_TYPE logDet, unsigned D, unsigned N, bool diagFl ) -{ - unsigned i; - - double fact = (-(cmReal_t)D/2) * log(2.0*M_PI) - 0.5*logDet; - - for(i=0; i M_PI) + dev_rads -= 2*M_PI; + + while( dev_rads < -M_PI) + dev_rads += 2*M_PI; + + // convert into rect coord's + double m1r = *mag1V++; + double m0r = *mag0V * cos(dev_rads); + double m0i = *mag0V++ * sin(dev_rads); + + // calc the combined amplitude and phase deviation + // sum += hypot( m1 - (m0 * e^(-1*dev_rads))); + + sum += hypot( m1r-m0r, -m0i ); + } - *b1 = (sxy * n - sx * sy) / (sx_2 * n - sx*sx); - *b0 = (sy - (*b1) * sx) / n; - + return (VECT_OP_TYPE)sum; } +VECT_OP_TYPE* VECT_OP_FUNC(DctMatrix)( VECT_OP_TYPE* dp, unsigned coeffCnt, unsigned filtCnt ) +{ + VECT_OP_TYPE* dbp = dp; + + double c0 = 1.0/sqrt(filtCnt/2); // row 1-coeffCnt factor + double c1 = c0 * sqrt(2)/2; // row 0 factor + + unsigned i,j; + + // for each column + for(i=0; i *s2p) && (*s1p >= threshold) ) + { + *dbp++ = s1p - sbp; + s0p = s2p++; + s1p = s2p++; + ++pkCnt; + } + else + { + s0p = s1p; + s1p = s2p++; + } + } + + return pkCnt; +} + +unsigned VECT_OP_FUNC(BinIndex)( const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE v ) +{ + const VECT_OP_TYPE* sep = sbp + sn; + const VECT_OP_TYPE* bp = sbp; + sep--; + for(; sbp < sep; ++sbp ) + if( *sbp <= v && v < *(sbp+1) ) + return sbp - bp; + + return cmInvalidIdx; +} + + void VECT_OP_FUNC(Interp1)(VECT_OP_TYPE* y1, const VECT_OP_TYPE* x1, unsigned xy1N, const VECT_OP_TYPE* x0, const VECT_OP_TYPE* y0, unsigned xy0N ) diff --git a/src/vop/cmVectOpsTemplateHdr.h b/src/vop/cmVectOpsTemplateHdr.h index c74159d..cb5da55 100644 --- a/src/vop/cmVectOpsTemplateHdr.h +++ b/src/vop/cmVectOpsTemplateHdr.h @@ -1,7 +1,21 @@ -// \file cmVectOpsTemplateHdr.h -/// Vector operations interface. +//( { label:misc desc:"Miscellaneous vector operations." kw:[vop] } -/// Setting fieldWidth or decPltCnt to to negative values result in fieldWidth == 10 or decPlCnt == 4 +// Compute the cummulative sum of sbp[dn]. Equivalent to Matlab cumsum(). +VECT_OP_TYPE* VECT_OP_FUNC(CumSum)(VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp ); + +// Returns true if all values in each vector are equal. +bool VECT_OP_FUNC(Equal)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ); + +// Same as Matlab linspace() v[i] = i * (limit-1)/n +VECT_OP_TYPE* VECT_OP_FUNC(LinSpace)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE base, VECT_OP_TYPE limit ); + +//====================================================================================================================== +//) + + +//( { label:Print desc:"Vector printing functions." kw:[vop] } +// Setting fieldWidth or decPltCnt to to negative values result in fieldWidth == 10 or decPlCnt == 4 +// void VECT_OP_FUNC(Printf)( cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp, int fieldWidth, int decPlCnt, const char* fmt, unsigned flags ); void VECT_OP_FUNC(Print)( cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp ); void VECT_OP_FUNC(PrintE)( cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp ); @@ -9,64 +23,68 @@ void VECT_OP_FUNC(PrintE)( cmRpt_t* rpt, unsigned rn, unsigned cn, cons void VECT_OP_FUNC(PrintLf)( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp, unsigned fieldWidth, unsigned decPlCnt, const char* fmt ); void VECT_OP_FUNC(PrintL)( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp ); void VECT_OP_FUNC(PrintLE)( const char* label, cmRpt_t* rpt, unsigned rn, unsigned cn, const VECT_OP_TYPE* dbp ); +//====================================================================================================================== +//) +//( { label:Normalization desc:"Normalization and standardization functions." kw:[vop] } -/// Normalize the vector of proabilities by dividing through by the sum. -/// This leaves the relative proportions of each value unchanged while producing a total probability of 1.0. +// Normalize the vector of proabilities by dividing through by the sum. +// This leaves the relative proportions of each value unchanged while producing a total probability of 1.0. +// VECT_OP_TYPE* VECT_OP_FUNC(NormalizeProbabilityVV)(VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp); VECT_OP_TYPE* VECT_OP_FUNC(NormalizeProbability)(VECT_OP_TYPE* dbp, unsigned dn); VECT_OP_TYPE* VECT_OP_FUNC(NormalizeProbabilityN)(VECT_OP_TYPE* dbp, unsigned dn, unsigned stride); - -/// Standardize the columns of the matrix by subtracting the mean and dividing by the standard deviation. -/// uV[dcn] returns the mean of the data and is optional. -/// sdV[dcn] return the standard deviation of the data and is optional. +// +// Standardize the columns of the matrix by subtracting the mean and dividing by the standard deviation. +// uV[dcn] returns the mean of the data and is optional. +// sdV[dcn] return the standard deviation of the data and is optional. VECT_OP_TYPE* VECT_OP_FUNC(StandardizeRows)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, VECT_OP_TYPE* uV, VECT_OP_TYPE* sdV ); VECT_OP_TYPE* VECT_OP_FUNC(StandardizeCols)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, VECT_OP_TYPE* uV, VECT_OP_TYPE* sdV ); +// +// Normalize by dividing through by the max. value. +// dp[] ./= max(dp). Returns the index of the max value. +unsigned VECT_OP_FUNC(NormToMax)( VECT_OP_TYPE* dp, unsigned dn ); +// +// Normalize by dividing through by the max. absolute value. +// db[] .*= fact / abs(max(dp)); +unsigned VECT_OP_FUNC(NormToAbsMax)( VECT_OP_TYPE* dp, unsigned dn, VECT_OP_TYPE fact ); +//====================================================================================================================== +//) -/// dbp[] = sbp<0 .* sbp -/// Overlapping the source and dest is allowable as long as dbp <= sbp. -VECT_OP_TYPE* VECT_OP_FUNC(HalfWaveRectify)(VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp ); -/// Compute the cummulative sum of sbp[dn]. Equivalent to Matlab cumsum(). -VECT_OP_TYPE* VECT_OP_FUNC(CumSum)(VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp ); +//( { label:"Mean and variance" desc:"Compute mean and variance." kw:[vop] } VECT_OP_TYPE VECT_OP_FUNC(Mean)( const VECT_OP_TYPE* sp, unsigned sn ); VECT_OP_TYPE VECT_OP_FUNC(MeanN)( const VECT_OP_TYPE* sp, unsigned sn, unsigned stride ); - +// // Take the mean of each column/row of a matrix. // Set 'dim' to 0 to return mean of columns else return mean of rows. VECT_OP_TYPE* VECT_OP_FUNC(MeanM)( VECT_OP_TYPE* dp, const VECT_OP_TYPE* sp, unsigned srn, unsigned scn, unsigned dim ); - +// // Take the mean of the first 'cnt' element of each column/row of a matrix. // Set 'dim' to 0 to return mean of columns else return mean of rows. // If 'cnt' is greater than the number of elements in the column/row then 'cnt' is // reduced to the number of elements in the column/row. VECT_OP_TYPE* VECT_OP_FUNC(MeanM2)( VECT_OP_TYPE* dp, const VECT_OP_TYPE* sp, unsigned srn, unsigned scn, unsigned dim, unsigned cnt ); - +// // Find the mean of the data points returned by srcFuncPtr(argPtr,i) and return it in dp[dim]. // 'dim' is both the size of dp[] and the length of each data point returned by srcFuncPtr(). // srcFuncPtr() will be called 'cnt' times but it may return NULL on some calls if the associated // data point should not be included in the mean calculation. VECT_OP_TYPE* VECT_OP_FUNC(Mean2)( VECT_OP_TYPE* dp, const VECT_OP_TYPE* (*srcFuncPtr)(void* arg, unsigned idx ), unsigned dim, unsigned cnt, void* argPtr ); - - +// // avgPtr is optional - set to NULL to compute the average VECT_OP_TYPE VECT_OP_FUNC(Variance)( const VECT_OP_TYPE* sp, unsigned sn, const VECT_OP_TYPE* avgPtr ); VECT_OP_TYPE VECT_OP_FUNC(VarianceN)(const VECT_OP_TYPE* sp, unsigned sn, unsigned stride, const VECT_OP_TYPE* avgPtr ); - +// // Set dim=0 to return variance of columns otherwise return variance or rows. VECT_OP_TYPE* VECT_OP_FUNC(VarianceM)(VECT_OP_TYPE* dp, const VECT_OP_TYPE* sp, unsigned srn, unsigned scn, const VECT_OP_TYPE* avgPtr, unsigned dim ); - -// dp[] ./= max(dp). Returns the index of the max value. -unsigned VECT_OP_FUNC(NormToMax)( VECT_OP_TYPE* dp, unsigned dn ); - -// db[] .*= fact / abs(max(dp)); -unsigned VECT_OP_FUNC(NormToAbsMax)( VECT_OP_TYPE* dp, unsigned dn, VECT_OP_TYPE fact ); +//====================================================================================================================== +//) -VECT_OP_TYPE VECT_OP_FUNC(AlphaNorm)(const VECT_OP_TYPE* sp, unsigned sn, VECT_OP_TYPE alpha ); - +//( { label:"Covariance" desc:"Matrix covariance" kw:[vop] } // Calculate the sample covariance matrix from a set of Gaussian distributed multidimensional data. // sp[dn,scn] is the data set. @@ -92,8 +110,10 @@ void VECT_OP_FUNC(GaussCovariance)(VECT_OP_TYPE* dp, unsigned dn, const VECT_OP // through the 'sn' data points. // The result of this function are identical to the octave cov() function. void VECT_OP_FUNC(GaussCovariance2)(VECT_OP_TYPE* dp, unsigned dn, const VECT_OP_TYPE* (*srcFuncPtr)(void* userPtr, unsigned idx), unsigned sn, void* userPtr, const VECT_OP_TYPE* uV, const unsigned* selIdxV, unsigned selKey ); +//====================================================================================================================== +//) -bool VECT_OP_FUNC(Equal)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ); +//( { label:"Float point normal" desc:"Evaluate the 'normalness of floating point values." kw:[vop] } // Returns true if all values are 'normal' according the the C macro 'isnormal'. // This function will return false if any of the values are zero. @@ -107,80 +127,90 @@ bool VECT_OP_FUNC(IsNormalZ)(const VECT_OP_TYPE* sp, unsigned sn ); // Returns the count of indexes stored in dp[]. unsigned VECT_OP_FUNC(FindNonNormal)( unsigned* dp, unsigned dn, const VECT_OP_TYPE* sp ); unsigned VECT_OP_FUNC(FindNonNormalZ)( unsigned* dp, unsigned dn, const VECT_OP_TYPE* sp ); +//====================================================================================================================== +//) -/// Successive call to to ZeroCrossCount should preserve the value pointed to by delaySmpPtr. +//( { label:"Measure" desc:"Measure features of a vector." kw:[vop] } + +// Successive call to to ZeroCrossCount should preserve the value pointed to by delaySmpPtr. unsigned VECT_OP_FUNC(ZeroCrossCount)( const VECT_OP_TYPE* sp, unsigned n, VECT_OP_TYPE* delaySmpPtr); // Calculuate the sum of the squares of all elements in bp[bn]. VECT_OP_TYPE VECT_OP_FUNC(SquaredSum)( const VECT_OP_TYPE* bp, unsigned bn ); -/// sn must be <= wndSmpCnt. If sn < wndSmpCnt then sp[sn] is treated as a -/// a partially filled buffer padded with wndSmpCnt-sn zeros. -/// rms = sqrt( sum(sp[1:sn] .* sp[1:sn]) / wndSmpCnt ) +// sn must be <= wndSmpCnt. If sn < wndSmpCnt then sp[sn] is treated as a +// a partially filled buffer padded with wndSmpCnt-sn zeros. +// rms = sqrt( sum(sp[1:sn] .* sp[1:sn]) / wndSmpCnt ) VECT_OP_TYPE VECT_OP_FUNC(RMS)( const VECT_OP_TYPE* sp, unsigned sn, unsigned wndSmpCnt ); -/// This function handles the case were sn is not an integer multiple of -/// wndSmpCnt or hopSmpCnt. In this case the function computes zero -/// padded RMS values for windows which go past the end of sp[sn]. +// This function handles the case were sn is not an integer multiple of +// wndSmpCnt or hopSmpCnt. In this case the function computes zero +// padded RMS values for windows which go past the end of sp[sn]. VECT_OP_TYPE* VECT_OP_FUNC(RmsV)( VECT_OP_TYPE* dp, unsigned dn, const VECT_OP_TYPE* sp, unsigned sn, unsigned wndSmpCnt, unsigned hopSmpCnt ); - -/// Return the magnitude (Euclidean Norm) of a vector. +// Return the magnitude (Euclidean Norm) of a vector. VECT_OP_TYPE VECT_OP_FUNC(EuclidNorm)( const VECT_OP_TYPE* sp, unsigned sn ); +VECT_OP_TYPE VECT_OP_FUNC(AlphaNorm)(const VECT_OP_TYPE* sp, unsigned sn, VECT_OP_TYPE alpha ); + +//====================================================================================================================== +//) + + + +//( { label:"Distance" desc:"Calculate various vector distances." kw:[vop] } + // Return the Itakura-Saito distance between a modelled power spectrum (up) and another power spectrum (sp). VECT_OP_TYPE VECT_OP_FUNC(ItakuraDistance)( const VECT_OP_TYPE* up, const VECT_OP_TYPE* sp, unsigned sn ); -/// Return the cosine distance between two vectors. +// Return the cosine distance between two vectors. VECT_OP_TYPE VECT_OP_FUNC(CosineDistance)( const VECT_OP_TYPE* s0P, const VECT_OP_TYPE* s1p, unsigned sn ); -/// Return the Euclidean distance between two vectors +// Return the Euclidean distance between two vectors VECT_OP_TYPE VECT_OP_FUNC(EuclidDistance)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ); -/// Return the Manhattan distance between two vectors +// Return the Manhattan distance between two vectors VECT_OP_TYPE VECT_OP_FUNC(L1Distance)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ); -/// Return the Mahalanobis distance between a vector and the mean of the distribution. -/// The mean vector could be replaced with another vector drawn from the same distribution in which -/// case the returned value would reflect the distance between the two vectors. -/// 'sn' is the dimensionality of the data. -/// up[D] and invCovM[sn,sn] are the mean and inverse of the covariance matrix of the distribution from -/// which sp[D] is drawn. +// Return the Mahalanobis distance between a vector and the mean of the distribution. +// The mean vector could be replaced with another vector drawn from the same distribution in which +// case the returned value would reflect the distance between the two vectors. +// 'sn' is the dimensionality of the data. +// up[D] and invCovM[sn,sn] are the mean and inverse of the covariance matrix of the distribution from +// which sp[D] is drawn. VECT_OP_TYPE VECT_OP_FUNC(MahalanobisDistance)( const VECT_OP_TYPE* sp, unsigned sn, const VECT_OP_TYPE* up, const VECT_OP_TYPE* invCovM ); -/// Return the KL distance between two probability distributions up[sn] and sp[sn]. -/// Since up[] and sp[] are probability distributions they must sum to 1.0. +// Return the KL distance between two probability distributions up[sn] and sp[sn]. +// Since up[] and sp[] are probability distributions they must sum to 1.0. VECT_OP_TYPE VECT_OP_FUNC(KL_Distance)( const VECT_OP_TYPE* up, const VECT_OP_TYPE* sp, unsigned sn ); -/// Return the KL distance between a prototype vector up[sn] and another vector sp[sn]. -/// This function first normalizes the two vectors to sum to 1.0 before calling +// Return the KL distance between a prototype vector up[sn] and another vector sp[sn]. +// This function first normalizes the two vectors to sum to 1.0 before calling // VECT_OP_FUNC(KL_Distance)(up,sp,sn); VECT_OP_TYPE VECT_OP_FUNC(KL_Distance2)( const VECT_OP_TYPE* up, const VECT_OP_TYPE* sp, unsigned sn ); -/// Measure the Euclidean distance between a vector and all the columns in a matrix. -/// If dv[scn] is no NULL then return the Euclidean distance from sv[scn] to each column of sm[srn,scn]. -/// The function returns the index of the closest data point (column) in sm[]. +// Measure the Euclidean distance between a vector and all the columns in a matrix. +// If dv[scn] is no NULL then return the Euclidean distance from sv[scn] to each column of sm[srn,scn]. +// The function returns the index of the closest data point (column) in sm[]. unsigned VECT_OP_FUNC(EuclidDistanceVM)( VECT_OP_TYPE* dv, const VECT_OP_TYPE* sv, const VECT_OP_TYPE* sm, unsigned srn, unsigned scn ); - - -/// Measure the distance between each column in s0M[ rn, s0cn ] and -/// each column in s1M[rn, s1cn ]. If dM is non-NULL store the -/// result in dM[s1cn, s0cn]. The difference between s0M[:,0] and s1M[:,0] -/// is stored in dM[0,0], the diff. between s0M[:,1] and s1M[:,1] is stored -/// in dM[1,0], etc. If mvV[s0cn] is non-NULL then minV[i] is set with -/// the distance from s0M[:,i] to the nearest column in s1M[]. If miV[s0cn] -/// is non-NULL then it is set with the column index of s1M[] which is -/// closest to s0M[:,i]. In other words mvV[i] gives the distance to column -/// miV[i] from column s0M[:,i]. -/// In those cases where the distane from a prototype (centroid) to the data point -/// is not the same as from the data point to the centroid then s1M[] is considered -/// to hold the prototypes and s0M[] is considered to hold the data points. -/// The distance function returns the distance from a prototype 'cV[dimN]' to -/// an datapoint dV[dimN]. 'dimN' is the dimensionality of the data vector -/// and is threfore equal to 'rn'. +// Measure the distance between each column in s0M[ rn, s0cn ] and +// each column in s1M[rn, s1cn ]. If dM is non-NULL store the +// result in dM[s1cn, s0cn]. The difference between s0M[:,0] and s1M[:,0] +// is stored in dM[0,0], the diff. between s0M[:,1] and s1M[:,1] is stored +// in dM[1,0], etc. If mvV[s0cn] is non-NULL then minV[i] is set with +// the distance from s0M[:,i] to the nearest column in s1M[]. If miV[s0cn] +// is non-NULL then it is set with the column index of s1M[] which is +// closest to s0M[:,i]. In other words mvV[i] gives the distance to column +// miV[i] from column s0M[:,i]. +// In those cases where the distane from a prototype (centroid) to the data point +// is not the same as from the data point to the centroid then s1M[] is considered +// to hold the prototypes and s0M[] is considered to hold the data points. +// The distance function returns the distance from a prototype 'cV[dimN]' to +// an datapoint dV[dimN]. 'dimN' is the dimensionality of the data vector +// and is threfore equal to 'rn'. void VECT_OP_FUNC(DistVMM)( VECT_OP_TYPE* dM, // dM[s1cn,s0cn] return distance mtx (optional) VECT_OP_TYPE* mvV, // mvV[s0cn] distance to closest data point in s0M[]. (optional) @@ -193,192 +223,238 @@ void VECT_OP_FUNC(DistVMM)( VECT_OP_TYPE (*distFunc)( void* userPtr, const VECT_OP_TYPE* cV, const VECT_OP_TYPE* dV, unsigned dimN ), void* userPtr ); -/// Select 'selIdxN' columns from sM[srn,scn]. -/// dM[srn,selIdxN] receives copies of the selected columns. -/// selIdxV[selIdxN] receives the column indexes of the selected columns. -/// Both dM[] and selIdxV[] are optional. -/// In each case the first selected point is chosen at random. -/// SelectRandom() then selects the following selIdxN-1 points at random. -/// SelectMaxDist() selects the next selIdxN-1 points by selecting -/// the point whose combined distance to the previously selected points -/// is greatest. SelectMaxAvgDist() selectes the points whose combined -/// average distance is greatest relative the the previously selected -/// points. +//====================================================================================================================== +//) + +//( { label:"Select columns" desc:"Select columns based on distance." kw:[vop] } + +// Select 'selIdxN' columns from sM[srn,scn]. +// dM[srn,selIdxN] receives copies of the selected columns. +// selIdxV[selIdxN] receives the column indexes of the selected columns. +// Both dM[] and selIdxV[] are optional. +// In each case the first selected point is chosen at random. +// SelectRandom() then selects the following selIdxN-1 points at random. +// SelectMaxDist() selects the next selIdxN-1 points by selecting +// the point whose combined distance to the previously selected points +// is greatest. SelectMaxAvgDist() selectes the points whose combined +// average distance is greatest relative the the previously selected +// points. void VECT_OP_FUNC(SelectRandom)( VECT_OP_TYPE* dM, unsigned* selIdxV, unsigned selIdxN, const VECT_OP_TYPE* sM, unsigned srn, unsigned scn ); void VECT_OP_FUNC(SelectMaxDist)( VECT_OP_TYPE* dM, unsigned* selIdxV, unsigned selIdxN, const VECT_OP_TYPE* sM, unsigned srn, unsigned scn, VECT_OP_TYPE (*distFunc)( void* userPtr, const VECT_OP_TYPE* s0V, const VECT_OP_TYPE* s1V, unsigned sn ), void* distUserPtr ); void VECT_OP_FUNC(SelectMaxAvgDist)( VECT_OP_TYPE* dM, unsigned* selIdxV, unsigned selIdxN, const VECT_OP_TYPE* sM, unsigned srn, unsigned scn, VECT_OP_TYPE (*distFunc)( void* userPtr, const VECT_OP_TYPE* s0V, const VECT_OP_TYPE* s1V, unsigned sn ), void* distUserPtr ); -/// Return the sum of the products (dot product) +//====================================================================================================================== +//) + +//( { label:"Matrix multiplication" desc:"Various matrix multiplication operations." kw:[vop] } + +// Return the sum of the products (dot product) VECT_OP_TYPE VECT_OP_FUNC(MultSumVV)( const VECT_OP_TYPE* s0p, const VECT_OP_TYPE* s1p, unsigned sn ); VECT_OP_TYPE VECT_OP_FUNC(MultSumVS)( const VECT_OP_TYPE* s0p, unsigned sn, VECT_OP_TYPE s ); -/// Number of elements in the dest vector is expected to be the same -/// as the number of source matrix rows. -/// mcn gives the number of columns in the source matrix which is +// Number of elements in the dest vector is expected to be the same +// as the number of source matrix rows. +// mcn gives the number of columns in the source matrix which is // expected to match the number of elements in the source vector. -/// dbp[dn,1] = mp[dn,mcn] * vp[mcn,1] +// dbp[dn,1] = mp[dn,mcn] * vp[mcn,1] VECT_OP_TYPE* VECT_OP_FUNC(MultVMV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* mp, unsigned mcn, const VECT_OP_TYPE* vp ); -/// Multiply a row vector with a matrix to produce a row vector. -/// dbp[1,dn] = v[1,vn] * m[vn,dn] +// Multiply a row vector with a matrix to produce a row vector. +// dbp[1,dn] = v[1,vn] * m[vn,dn] VECT_OP_TYPE* VECT_OP_FUNC(MultVVM)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* vp, unsigned vn, const VECT_OP_TYPE* mp ); -/// Same as MultVMtV() except M is transposed as part of the multiply. -/// mrn gives the number of rows in m[] and number of elements in vp[] -/// dpb[dn] = mp[mrn,dn] * vp[mrn] +// Same as MultVMtV() except M is transposed as part of the multiply. +// mrn gives the number of rows in m[] and number of elements in vp[] +// dpb[dn] = mp[mrn,dn] * vp[mrn] VECT_OP_TYPE* VECT_OP_FUNC(MultVMtV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* mp, unsigned mrn, const VECT_OP_TYPE* vp ); -/// Same as MultVMV() but where the matrix is diagonal. +// Same as MultVMV() but where the matrix is diagonal. VECT_OP_TYPE* VECT_OP_FUNC(MultDiagVMV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* mp, unsigned mcn, const VECT_OP_TYPE* vp ); -/// Generalized matrix multiply. -/// If transposition is selected for M0 or M1 then the given dimension represent the size of the matrix 'after' the transposion. -/// d[drn,dcn] = alpha * op(m0[drn,m0cn_m1rn]) * op(m1[m0cn_m1rn,dcn]) + beta * d[drn,dcn] -//// See enum { kTranpsoseM0Fl=0x01, kTransposeM1Fl=0x02 } in cmVectOps for flags. +// Generalized matrix multiply. +// If transposition is selected for M0 or M1 then the given dimension represent the size of the matrix 'after' the transposion. +// d[drn,dcn] = alpha * op(m0[drn,m0cn_m1rn]) * op(m1[m0cn_m1rn,dcn]) + beta * d[drn,dcn] +/// See enum { kTranpsoseM0Fl=0x01, kTransposeM1Fl=0x02 } in cmVectOps for flags. VECT_OP_TYPE* VECT_OP_FUNC(MultMMM1)(VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, VECT_OP_TYPE alpha, const VECT_OP_TYPE* m0, const VECT_OP_TYPE* m1, unsigned m0cn_m1rn, VECT_OP_TYPE beta, unsigned flags ); -/// Same a VECT_OP_FUNC(MultMMM1) except allows the operation on a sub-matrix by providing the physical (memory) row count rather than the logical (matrix) row count. +// Same a VECT_OP_FUNC(MultMMM1) except allows the operation on a sub-matrix by providing the physical (memory) row count rather than the logical (matrix) row count. VECT_OP_TYPE* VECT_OP_FUNC(MultMMM2)(VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, VECT_OP_TYPE alpha, const VECT_OP_TYPE* m0, const VECT_OP_TYPE* m1, unsigned m0cn_m1rn, VECT_OP_TYPE beta, unsigned flags, unsigned dprn, unsigned m0prn, unsigned m1prn ); -/// d[drn,dcn] = m0[drn,m0cn] * m1[m1rn,dcn] +// d[drn,dcn] = m0[drn,m0cn] * m1[m1rn,dcn] VECT_OP_TYPE* VECT_OP_FUNC(MultMMM)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* m0, const VECT_OP_TYPE* m1, unsigned m0cn_m1rn ); -/// same as MultMMM() except second source matrix is transposed prior to the multiply +// same as MultMMM() except second source matrix is transposed prior to the multiply VECT_OP_TYPE* VECT_OP_FUNC(MultMMMt)(VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* m0, const VECT_OP_TYPE* m1, unsigned m0cn_m1rn ); - -// Raise dbp[] to the power 'expon' -VECT_OP_TYPE* VECT_OP_FUNC(PowVS)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE expon ); -VECT_OP_TYPE* VECT_OP_FUNC(PowVVS)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp, VECT_OP_TYPE expon ); +//====================================================================================================================== +//) -// Take the natural log of all values in sbp[dn]. It is allowable for sbp point to the same array as dbp=. -VECT_OP_TYPE* VECT_OP_FUNC(LogV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp ); +//( { label:"Linear algebra" desc:"Miscellaneous linear algebra operations. Determinant, Inversion, Cholesky decompostion. Linear system solver." kw:[vop] } -// Convert a magnitude (amplitude) spectrum to/from decibels. -// It is allowable for dbp==sbp. -VECT_OP_TYPE* VECT_OP_FUNC(AmplToDbVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE minDb ); -VECT_OP_TYPE* VECT_OP_FUNC(DbToAmplVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp); - -VECT_OP_TYPE* VECT_OP_FUNC(PowToDbVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE minDb ); -VECT_OP_TYPE* VECT_OP_FUNC(DbToPowVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp); - -/// Initialize dbp[dn,dn] as a square symetric positive definite matrix using values -/// from a random uniform distribution. This is useful for initializing random -/// covariance matrices as used by multivariate Gaussian distributions -/// If t is non-NULL it must point to a block of scratch memory of t[dn,dn]. -/// If t is NULL then scratch memory is internally allocated and deallocated. +// Initialize dbp[dn,dn] as a square symetric positive definite matrix using values +// from a random uniform distribution. This is useful for initializing random +// covariance matrices as used by multivariate Gaussian distributions +// If t is non-NULL it must point to a block of scratch memory of t[dn,dn]. +// If t is NULL then scratch memory is internally allocated and deallocated. VECT_OP_TYPE* VECT_OP_FUNC(RandSymPosDef)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE* t ); - -/// Compute the determinant of any square matrix. +// Compute the determinant of any square matrix. VECT_OP_TYPE VECT_OP_FUNC(DetM)( const VECT_OP_TYPE* sp, unsigned srn ); -/// Compute the determinant of a diagonal matrix. +// Compute the determinant of a diagonal matrix. VECT_OP_TYPE VECT_OP_FUNC(DetDiagM)( const VECT_OP_TYPE* sp, unsigned srn); -/// Compute the log determinant of any square matrix. +// Compute the log determinant of any square matrix. VECT_OP_TYPE VECT_OP_FUNC(LogDetM)( const VECT_OP_TYPE* sp, unsigned srn ); -/// Compute the log determinant of a diagonal matrix. +// Compute the log determinant of a diagonal matrix. VECT_OP_TYPE VECT_OP_FUNC(LogDetDiagM)( const VECT_OP_TYPE* sp, unsigned srn); -/// Compute the inverse of a square matrix. Returns NULL if the matrix is not invertable. -/// 'drn' is the dimensionality of the data. +// Compute the inverse of a square matrix. Returns NULL if the matrix is not invertable. +// 'drn' is the dimensionality of the data. VECT_OP_TYPE* VECT_OP_FUNC(InvM)( VECT_OP_TYPE* dp, unsigned drn ); -/// Compute the inverse of a diagonal matrix. Returns NULL if the matrix is not invertable. +// Compute the inverse of a diagonal matrix. Returns NULL if the matrix is not invertable. VECT_OP_TYPE* VECT_OP_FUNC(InvDiagM)( VECT_OP_TYPE* dp, unsigned drn ); -/// Solve a linear system of the form AX=B where A[an,an] is square. -/// Since A is square B must have 'an' rows. -/// Result is returned in B. -/// Returns a pointer to B on success or NULL on fail. -/// NOTE: Both A and B are overwritten by this operation. +// Solve a linear system of the form AX=B where A[an,an] is square. +// Since A is square B must have 'an' rows. +// Result is returned in B. +// Returns a pointer to B on success or NULL on fail. +// NOTE: Both A and B are overwritten by this operation. VECT_OP_TYPE* VECT_OP_FUNC(SolveLS)( VECT_OP_TYPE* A, unsigned an, VECT_OP_TYPE* B, unsigned bcn ); -/// Perform a Cholesky decomposition of the square symetric matrix U[un,un]. -/// The factorization has the form: A=U'TU. -/// If the factorization is successful A is set to U and a pointer to A is returned. -/// Note that the lower triangle of A is not overwritten. See CholZ(). -/// If the factorization fails NULL is returned. +// Perform a Cholesky decomposition of the square symetric matrix U[un,un]. +// The factorization has the form: A=U'TU. +// If the factorization is successful A is set to U and a pointer to A is returned. +// Note that the lower triangle of A is not overwritten. See CholZ(). +// If the factorization fails NULL is returned. VECT_OP_TYPE* VECT_OP_FUNC(Chol)(VECT_OP_TYPE* A, unsigned an ); -/// Same as Chol() but sets the lower triangle of U to zero. -/// This is equivalent ot the Matlab version. +// Same as Chol() but sets the lower triangle of U to zero. +// This is equivalent ot the Matlab version. VECT_OP_TYPE* VECT_OP_FUNC(CholZ)(VECT_OP_TYPE* U, unsigned un ); +// Calculate the best fit line: b0 + b1*x_i through the points x_i,y_i. +// Set x to NULL if it uses sequential integers [0,1,2,3...] +void VECT_OP_FUNC(Lsq1)(const VECT_OP_TYPE* x, const VECT_OP_TYPE* y, unsigned n, VECT_OP_TYPE* b0, VECT_OP_TYPE* b1 ); -/// Return the average value of the contents of sbp[] between two fractional indexes + +//====================================================================================================================== +//) + +//( { label:"Stretch/Shrink" desc:"Stretch or shrink a vector by resampling." kw:[vop] } + +// Return the average value of the contents of sbp[] between two fractional indexes VECT_OP_TYPE VECT_OP_FUNC(FracAvg)( double bi, double ei, const VECT_OP_TYPE* sbp, unsigned sn ); -/// Shrinking function - Decrease the size of sbp[] by averaging blocks of values into single values in dbp[] +// Shrinking function - Decrease the size of sbp[] by averaging blocks of values into single values in dbp[] VECT_OP_TYPE* VECT_OP_FUNC(DownSampleAvg)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, unsigned sn ); -/// Stretching function - linear interpolate between points in sbp[] to fill dbp[] ... where dn > sn +// Stretching function - linear interpolate between points in sbp[] to fill dbp[] ... where dn > sn VECT_OP_TYPE* VECT_OP_FUNC(UpSampleInterp)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, unsigned sn ); -/// Stretch or shrink the sbp[] to fit into dbp[] +// Stretch or shrink the sbp[] to fit into dbp[] VECT_OP_TYPE* VECT_OP_FUNC(FitToSize)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, unsigned sn ); -/// Stretch or shrink sV[] to fit into dV[] using a simple linear mapping. -/// When stretching (sndn) each dest value is formed by the average of sequential segments -/// of sn/dn source elements. Fractional values are used at the beginning -/// and end of each segment. +// Stretch or shrink sV[] to fit into dV[] using a simple linear mapping. +// When stretching (sndn) each dest value is formed by the average of sequential segments +// of sn/dn source elements. Fractional values are used at the beginning +// and end of each segment. VECT_OP_TYPE* VECT_OP_FUNC(LinearMap)(VECT_OP_TYPE* dV, unsigned dn, VECT_OP_TYPE* sV, unsigned sn ); -/// Generate a vector of uniformly distributed random numbers in the range minVal to maxVal. +//====================================================================================================================== +//) + +//( { label:"Random number generation" desc:"Generate random numbers." kw:[vop] } + +// Generate a vector of uniformly distributed random numbers in the range minVal to maxVal. VECT_OP_TYPE* VECT_OP_FUNC(Random)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE minVal, VECT_OP_TYPE maxVal ); -/// Generate dn random numbers integers between 0 and wn-1 based on a the relative -/// weights in wp[wn]. Note thtat the weights do not have to sum to 1.0. +// Generate dn random numbers integers between 0 and wn-1 based on a the relative +// weights in wp[wn]. Note thtat the weights do not have to sum to 1.0. unsigned* VECT_OP_FUNC(WeightedRandInt)( unsigned* dbp, unsigned dn, const VECT_OP_TYPE* wp, unsigned wn ); -/// Generate a vector of normally distributed univariate random numbers +// Generate a vector of normally distributed univariate random numbers VECT_OP_TYPE* VECT_OP_FUNC(RandomGauss)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE mean, VECT_OP_TYPE var ); -/// Generate a vector of normally distributed univariate random numbers where each value has been drawn from a -/// seperately parameterized Gaussian distribution. meanV[] and varV[] must both contain dn velues. +// Generate a vector of normally distributed univariate random numbers where each value has been drawn from a +// seperately parameterized Gaussian distribution. meanV[] and varV[] must both contain dn velues. VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* varV ); -/// Generate a matrix of multi-dimensional random values. Each column represents a single vector value and each row contains a dimension. -/// meanV[] and varV[] must both contain drn elements where each meanV[i],varV[i] pair parameterize one dimensions Gaussian distribution. +// Generate a matrix of multi-dimensional random values. Each column represents a single vector value and each row contains a dimension. +// meanV[] and varV[] must both contain drn elements where each meanV[i],varV[i] pair parameterize one dimensions Gaussian distribution. VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussM)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* varV ); VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussDiagM)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* diagCovarM ); -/// Generate a matrix of multivariate random values drawn from a normal distribution. -/// The dimensionality of the values are 'drn'. -/// The count of returned values is 'dcn'. -/// meanV[drn] and covarM[drn,drn] parameterize the normal distribution. -/// The covariance matrix must be symetric and positive definite. -/// t[(drn*drn) ] points to scratch memory or is set to NULL if the function should -/// allocate the memory internally. -/// Based on octave function mvrnd.m. +// Generate a matrix of multivariate random values drawn from a normal distribution. +// The dimensionality of the values are 'drn'. +// The count of returned values is 'dcn'. +// meanV[drn] and covarM[drn,drn] parameterize the normal distribution. +// The covariance matrix must be symetric and positive definite. +// t[(drn*drn) ] points to scratch memory or is set to NULL if the function should +// allocate the memory internally. +// Based on octave function mvrnd.m. VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussNonDiagM)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* covarM, VECT_OP_TYPE* t ); -/// Same as RandomGaussNonDiagM() except requires the upper trianglular -/// Cholesky factor of the covar matrix in 'uM'. +// Same as RandomGaussNonDiagM() except requires the upper trianglular +// Cholesky factor of the covar matrix in 'uM'. VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussNonDiagM2)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* uM ); -/// Generate a matrix of N*K multi-dimensional data points. -/// Where D is the dimensionality of the data. (D == drn). -/// K is the number of multi-dimensional PDF's (clusters). -/// N is the number of data points to generate per cluster. -/// dbp[ D, N*K ] contains the returned data point. -/// The first N columns is associated with the cluster 0, -/// the next N columns is associated with cluster 1, ... -/// meanM[ D, K ] and varM[D,K] parameterize the generating PDF.s for each cluster +// Generate a matrix of N*K multi-dimensional data points. +// Where D is the dimensionality of the data. (D == drn). +// K is the number of multi-dimensional PDF's (clusters). +// N is the number of data points to generate per cluster. +// dbp[ D, N*K ] contains the returned data point. +// The first N columns is associated with the cluster 0, +// the next N columns is associated with cluster 1, ... +// meanM[ D, K ] and varM[D,K] parameterize the generating PDF.s for each cluster VECT_OP_TYPE* VECT_OP_FUNC(RandomGaussMM)( VECT_OP_TYPE* dbp, unsigned drn, unsigned dcn, const VECT_OP_TYPE* meanM, const VECT_OP_TYPE* varM, unsigned K ); -/// Generate the set of coordinates which describe a circle with a center at x,y. -/// dbp[dn,2] must contain 2*dn elements. The first column holds the x coord and and the second holds the y coord. -VECT_OP_TYPE* VECT_OP_FUNC(CircleCoords)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE x, VECT_OP_TYPE y, VECT_OP_TYPE varX, VECT_OP_TYPE varY ); -/// The following functions all return the phase of the next value. +// Evaluate the univariate normal distribution defined by 'mean' and 'stdDev'. +VECT_OP_TYPE* VECT_OP_FUNC(GaussPDF)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE mean, VECT_OP_TYPE stdDev ); + +// Evaluate a multivariate normal distribution defined by meanV[D] and covarM[D,D] +// at the data points held in the columns of xM[D,N]. Return the evaluation +// results in the vector yV[N]. D is the dimensionality of the data. N is the number of +// data points to evaluate and values to return in yV[N]. +// Set diagFl to true if covarM is diagonal. +// The function fails and returns false if the covariance matrix is singular. +bool VECT_OP_FUNC(MultVarGaussPDF)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* covarM, unsigned D, unsigned N, bool diagFl ); + +// Same as multVarGaussPDF[] except takes the inverse covar mtx invCovarM[D,D] +// and log determinant of covar mtx. +// Always returns yV[]. +VECT_OP_TYPE* VECT_OP_FUNC(MultVarGaussPDF2)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* invCovarM, VECT_OP_TYPE logDet, unsigned D, unsigned N, bool diagFl ); + +// Same as multVarGaussPDF[] except uses a function to obtain the data vectors. +// srcFunc() can filter the data points by returning NULL if the data vector at frmIdx should +// not be evaluated against the PDF. In this case yV[frmIdx] will be set to 0. +VECT_OP_TYPE* VECT_OP_FUNC(MultVarGaussPDF3)( + VECT_OP_TYPE* yV, + const VECT_OP_TYPE* (*srcFunc)(void* funcDataPtr, unsigned frmIdx ), + void* funcDataPtr, + const VECT_OP_TYPE* meanV, + const VECT_OP_TYPE* invCovarM, + VECT_OP_TYPE logDet, + unsigned D, + unsigned N, + bool diagFl ); + + +//====================================================================================================================== +//) + + +//( { label:"Signal generators" desc:"Generate periodic signals." kw:[vop] } + +// The following functions all return the phase of the next value. unsigned VECT_OP_FUNC(SynthSine)( VECT_OP_TYPE* dbp, unsigned dn, unsigned phase, double srate, double hz ); unsigned VECT_OP_FUNC(SynthCosine)( VECT_OP_TYPE* dbp, unsigned dn, unsigned phase, double srate, double hz ); unsigned VECT_OP_FUNC(SynthSquare)( VECT_OP_TYPE* dbp, unsigned dn, unsigned phase, double srate, double hz, unsigned otCnt ); @@ -389,11 +465,33 @@ unsigned VECT_OP_FUNC(SynthImpulse)( VECT_OP_TYPE* dbp, unsigned dn, unsi unsigned VECT_OP_FUNC(SynthPhasor)( VECT_OP_TYPE* dbp, unsigned dn, unsigned phase, double srate, double hz ); -/// Return value should be passed back via delaySmp on the next call. +// Return value should be passed back via delaySmp on the next call. VECT_OP_TYPE VECT_OP_FUNC(SynthPinkNoise)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE delaySmp ); -/// Same as Matlab linspace() v[i] = i * (limit-1)/n -VECT_OP_TYPE* VECT_OP_FUNC(LinSpace)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE base, VECT_OP_TYPE limit ); +//====================================================================================================================== +//) + +//( { label:"Exponential conversion" desc:"pow() and log() functions." kw:[vop] } + +// Raise dbp[] to the power 'expon' +VECT_OP_TYPE* VECT_OP_FUNC(PowVS)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE expon ); +VECT_OP_TYPE* VECT_OP_FUNC(PowVVS)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp, VECT_OP_TYPE expon ); + +// Take the natural log of all values in sbp[dn]. It is allowable for sbp point to the same array as dbp=. +VECT_OP_TYPE* VECT_OP_FUNC(LogV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp ); + +//====================================================================================================================== +//) + +//( { label:"dB Conversions" desc:"Convert vectors between dB,linear and power representations." kw:[vop] } + +// Convert a magnitude (amplitude) spectrum to/from decibels. +// It is allowable for dbp==sbp. +VECT_OP_TYPE* VECT_OP_FUNC(AmplToDbVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE minDb ); +VECT_OP_TYPE* VECT_OP_FUNC(DbToAmplVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp); + +VECT_OP_TYPE* VECT_OP_FUNC(PowToDbVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE minDb ); +VECT_OP_TYPE* VECT_OP_FUNC(DbToPowVV)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp); VECT_OP_TYPE* VECT_OP_FUNC(LinearToDb)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp, VECT_OP_TYPE mult ); VECT_OP_TYPE* VECT_OP_FUNC(dBToLinear)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp, VECT_OP_TYPE mult ); @@ -401,6 +499,10 @@ VECT_OP_TYPE* VECT_OP_FUNC(AmplitudeToDb)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* VECT_OP_FUNC(PowerToDb)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp ); VECT_OP_TYPE* VECT_OP_FUNC(dBToAmplitude)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp ); VECT_OP_TYPE* VECT_OP_FUNC(dBToPower)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sp ); +//====================================================================================================================== +//) + +//( { label:"DSP Windows" desc:"DSP windowing functions." kw:[vop] } VECT_OP_TYPE VECT_OP_FUNC(KaiserBetaFromSidelobeReject)( double sidelobeRejectDb ); VECT_OP_TYPE VECT_OP_FUNC(KaiserFreqResolutionFactor)( double sidelobeRejectDb ); @@ -410,84 +512,86 @@ VECT_OP_TYPE* VECT_OP_FUNC(Hamming)( VECT_OP_TYPE* dbp, unsigned dn ); VECT_OP_TYPE* VECT_OP_FUNC(Hann)( VECT_OP_TYPE* dbp, unsigned dn ); VECT_OP_TYPE* VECT_OP_FUNC(Triangle)(VECT_OP_TYPE* dbp, unsigned dn ); -/// The MATLAB equivalent Hamming and Hann windows. +// The MATLAB equivalent Hamming and Hann windows. //VECT_OP_TYPE* VECT_OP_FUNC(HammingMatlab)(VECT_OP_TYPE* dbp, unsigned dn ); VECT_OP_TYPE* VECT_OP_FUNC(HannMatlab)( VECT_OP_TYPE* dbp, unsigned dn ); -/// Simulates the MATLAB GaussWin function. Set arg to 2.5 to simulate the default arg -/// as used by MATLAB. +// Simulates the MATLAB GaussWin function. Set arg to 2.5 to simulate the default arg +// as used by MATLAB. VECT_OP_TYPE* VECT_OP_FUNC(GaussWin)( VECT_OP_TYPE* dbp, unsigned dn, double arg ); +//====================================================================================================================== +//) +//( { label:"DSP Filters" desc:"DSP filtering functions." kw:[vop] } -/// Direct form II algorithm based on the MATLAB implmentation -/// http://www.mathworks.com/access/helpdesk/help/techdoc/ref/filter.html#f83-1015962 -/// The only difference between this function and the equivalent MATLAB filter() function -/// is that the first feedforward coeff is given as a seperate value. The first b coefficient -/// in this function is therefore the same as the second coefficient in the MATLAB function. -/// and the first a[] coefficient (which is generally set to 1.0) is skipped. -/// Example: -/// Matlab: b=[.5 .4 .3] a=[1 .2 .1] -/// Equiv: b0 = .5 b=[ .4 .3] a=[ .2 .1]; -/// -/// y[yn] - output vector -/// x[xn] - input vector. xn must be <= yn. if xn < yn then the end of y[] is set to zero. -/// b0 - signal scale. This can also be seen as b[0] (which is not included in b[]) -/// b[dn] - feedforward coeff's b[1..dn-1] -/// a[dn] - feedback coeff's a[1..dn-1] -/// d[dn+1] - delay registers - note that this array must be one element longer than the coeff arrays. -/// +// Direct form II algorithm based on the MATLAB implmentation +// http://www.mathworks.com/access/helpdesk/help/techdoc/ref/filter.html#f83-1015962 +// The only difference between this function and the equivalent MATLAB filter() function +// is that the first feedforward coeff is given as a seperate value. The first b coefficient +// in this function is therefore the same as the second coefficient in the MATLAB function. +// and the first a[] coefficient (which is generally set to 1.0) is skipped. +// Example: +// Matlab: b=[.5 .4 .3] a=[1 .2 .1] +// Equiv: b0 = .5 b=[ .4 .3] a=[ .2 .1]; +// +// y[yn] - output vector +// x[xn] - input vector. xn must be <= yn. if xn < yn then the end of y[] is set to zero. +// b0 - signal scale. This can also be seen as b[0] (which is not included in b[]) +// b[dn] - feedforward coeff's b[1..dn-1] +// a[dn] - feedback coeff's a[1..dn-1] +// d[dn+1] - delay registers - note that this array must be one element longer than the coeff arrays. +// VECT_OP_TYPE* VECT_OP_FUNC(Filter)( VECT_OP_TYPE* y, unsigned yn, const VECT_OP_TYPE* x, unsigned xn, cmReal_t b0, const cmReal_t* b, const cmReal_t* a, cmReal_t* d, unsigned dn ); struct cmFilter_str; //typedef cmRC_t (*VECT_OP_FUNC(FiltExecFunc_t))( struct acFilter_str* f, const VECT_OP_TYPE* x, unsigned xn, VECT_OP_TYPE* y, unsigned yn ); VECT_OP_TYPE* VECT_OP_FUNC(FilterFilter)(struct cmFilter_str* f, cmRC_t (*func)( struct cmFilter_str* f, const VECT_OP_TYPE* x, unsigned xn, VECT_OP_TYPE* y, unsigned yn ), const cmReal_t bb[], unsigned bn, const cmReal_t aa[], unsigned an, const VECT_OP_TYPE* x, unsigned xn, VECT_OP_TYPE* y, unsigned yn ); -/// Compute the coefficients of a low/high pass FIR filter -/// wndV[dn] gives the window function used to truncate the ideal low-pass impulse response. -/// Set wndV to NULL to use a unity window. -/// See enum { kHighPass_LPSincFl=0x01, kNormalize_LPSincFl=0x02 } in cmVectOps.h +// Compute the coefficients of a low/high pass FIR filter +// wndV[dn] gives the window function used to truncate the ideal low-pass impulse response. +// Set wndV to NULL to use a unity window. +// See enum { kHighPass_LPSincFl=0x01, kNormalize_LPSincFl=0x02 } in cmVectOps.h VECT_OP_TYPE* VECT_OP_FUNC(LP_Sinc)(VECT_OP_TYPE* dp, unsigned dn, const VECT_OP_TYPE* wndV, double srate, double fcHz, unsigned flags ); -/// Compute the complex transient detection function from successive spectral frames. -/// The spectral magntidue mag0V precedes mag1V and the phase (radians) spectrum phs0V precedes the phs1V which precedes phs2V. -/// binCnt gives the length of each of the spectral vectors. -VECT_OP_TYPE VECT_OP_FUNC(ComplexDetect)(const VECT_OP_TYPE* mag0V, const VECT_OP_TYPE* mag1V, const VECT_OP_TYPE* phs0V, const VECT_OP_TYPE* phs1V, const VECT_OP_TYPE* phs2V, unsigned binCnt ); -/// Compute a set of filterCnt mel filter masks for wieghting magnitude spectra consisting of binCnt bins. -/// The spectrum is divided into bandCnt equal bands in the mel domain -/// Each row of the matrix contains the mask for a single filter band consisting of binCnt elements. -/// See enum{ kShiftMelFl=0x01, kNormalizeMelFl=0x02 } in cmVectOps.h -/// Set kShiftMelFl to shift the mel bands onto the nearest FFT bin. -/// Set kNormalizeMelFl to normalize the combined filters for unity gain. +//====================================================================================================================== +//) + +//( { label:"Spectral Masking" desc:"A collection of spectral masking functions." kw:[vop] } + +// Compute a set of filterCnt mel filter masks for wieghting magnitude spectra consisting of binCnt bins. +// The spectrum is divided into bandCnt equal bands in the mel domain +// Each row of the matrix contains the mask for a single filter band consisting of binCnt elements. +// See enum{ kShiftMelFl=0x01, kNormalizeMelFl=0x02 } in cmVectOps.h +// Set kShiftMelFl to shift the mel bands onto the nearest FFT bin. +// Set kNormalizeMelFl to normalize the combined filters for unity gain. VECT_OP_TYPE* VECT_OP_FUNC(MelMask)( VECT_OP_TYPE* maskMtx, unsigned bandCnt, unsigned binCnt, double srate, unsigned flags ); - - -/// Fill binIdxV[bandCnt] and cntV[bandCnt] with a bin to band map. -/// binIdx[] contains the first (minimum) bin index for a given band. -/// cntV[] contains the count of bins for each band. -/// bandCnt is the number of bark bands to return -/// The function returns the actual number of bands mapped which will always be <= 23. +// Fill binIdxV[bandCnt] and cntV[bandCnt] with a bin to band map. +// binIdx[] contains the first (minimum) bin index for a given band. +// cntV[] contains the count of bins for each band. +// bandCnt is the number of bark bands to return +// The function returns the actual number of bands mapped which will always be <= 23. unsigned VECT_OP_FUNC(BarkMap)(unsigned* binIdxV, unsigned* cntV, unsigned bandCnt, unsigned binCnt, double srate ); -/// Calc a set of triangle fitler masks into each row of maskMtx. -/// maskMtx[ bandCnt, binCnt ] - result matrix -/// binHz - freq resolution of the output filters. -/// stSpread - Semi-tone spread above and below each center frequency (stSpread*2) is the total bandwidth. -/// (Only used if lowHzV or uprHzV are NULL) -/// lowHz[ bandCnt ] - set of upper frequency limits for each band. -/// ctrHz[ bandCnt ] set to the center value in Hz for each band -/// uprHz[ bandCnt ] - set of lower frequency limits for each band. -/// Note if lowHz[] and uprHz[] are set to NULL then stSpread is used to set the bandwidth of each band. +// Calc a set of triangle fitler masks into each row of maskMtx. +// maskMtx[ bandCnt, binCnt ] - result matrix +// binHz - freq resolution of the output filters. +// stSpread - Semi-tone spread above and below each center frequency (stSpread*2) is the total bandwidth. +// (Only used if lowHzV or uprHzV are NULL) +// lowHz[ bandCnt ] - set of upper frequency limits for each band. +// ctrHz[ bandCnt ] set to the center value in Hz for each band +// uprHz[ bandCnt ] - set of lower frequency limits for each band. +// Note if lowHz[] and uprHz[] are set to NULL then stSpread is used to set the bandwidth of each band. VECT_OP_TYPE* VECT_OP_FUNC(TriangleMask)(VECT_OP_TYPE* maskMtx, unsigned bandCnt, unsigned binCnt, const VECT_OP_TYPE* ctrHzV, VECT_OP_TYPE binHz, VECT_OP_TYPE stSpread, const VECT_OP_TYPE* lowHzV, const VECT_OP_TYPE* uprHzV ); -/// Calculate a set of Bark band triangle filters into maskMtx. -/// Each row of maskMtx contains the filter for one band. -/// maskMtx[ bandCnt, binCnt ] -/// bandCnt - the number of triangle bankds. If bandCnt is > 24 it will be reduced to 24. -/// binCnt - the number of bins in the filters. -/// binHz - the width of each bin in Hz. +// Calculate a set of Bark band triangle filters into maskMtx. +// Each row of maskMtx contains the filter for one band. +// maskMtx[ bandCnt, binCnt ] +// bandCnt - the number of triangle bankds. If bandCnt is > 24 it will be reduced to 24. +// binCnt - the number of bins in the filters. +// binHz - the width of each bin in Hz. VECT_OP_TYPE* VECT_OP_FUNC(BarkMask)(VECT_OP_TYPE* maskMtx, unsigned bandCnt, unsigned binCnt, double binHz ); // Terhardt 1979 (Calculating virtual pitch, Hearing Research #1, pp 155-182) @@ -497,39 +601,27 @@ VECT_OP_TYPE* VECT_OP_FUNC(TerhardtThresholdMask)(VECT_OP_TYPE* maskV, unsigned //Schroeder et al., 1979, JASA, Optimizing digital speech coders by exploiting masking properties of the human ear VECT_OP_TYPE* VECT_OP_FUNC(ShroederSpreadingFunc)(VECT_OP_TYPE* m, unsigned bandCnt, double srate); -/// Compute a set of DCT-II coefficients. Result dp[ coeffCnt, filtCnt ] -VECT_OP_TYPE* VECT_OP_FUNC(DctMatrix)( VECT_OP_TYPE* dp, unsigned coeffCnt, unsigned filtCnt ); +//====================================================================================================================== +//) +//( { label:"Machine learning" desc:"K-means clustering and Viterbi algorithms." kw:[vop] } -/// Set the indexes of local peaks greater than threshold in dbp[]. -/// Returns the number of peaks in dbp[] -/// The maximum number of peaks from n source values is max(0,floor((n-1)/2)). -/// Note that peaks will never be found at index 0 or index sn-1. -unsigned VECT_OP_FUNC(PeakIndexes)( unsigned* dbp, unsigned dn, const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE threshold ); - -/// Return the index of the bin containing v or acInvalidIdx if v is below sbp[0] or above sbp[ n-1 ] -/// The bin limits are contained in sbp[]. -/// The value in spb[] are therefore expected to be in increasing order. -/// The value returned will be in the range 0:sn-1. -unsigned VECT_OP_FUNC(BinIndex)( const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE v ); - - -/// Assign each data point to one of k clusters using an expectation-maximization algorithm. -/// k gives the number of clusters to identify -/// Each column of sp[ srn, scn ] contains a multidimensional data point. -/// srn therefore defines the dimensionality of the data. -/// Each column of centroidV[ srn, k ] is set to the centroid of each of k clusters. -/// classIdxV[ scn ] assigns the index (0 to k-1) of a cluster to each soure data point -/// The function returns the number of iterations required for the EM process to converge. -/// selIdxV[ scn ] is optional and contains a list of id's assoc'd with each column of sM. -/// selKey is a integer value. -/// If selIdxV is non-NULL then only columns of sM[] where selIdxV[] == selKey will be clustered. -/// All columns of sM[] where the associated column in selIdxV[] do not match will be ignored. -/// Set 'initFromCentroidFl' to true if the initial centroids should be taken from centroidM[]. -/// otherwise the initial centroids are selected from 'k' random data points in sp[]. -/// The distance function distFunc(cV,dV,dN) is called to determine the distance from a -/// centroid the centroid 'cV[dN]' to a data point 'dV[dN]'. 'dN' is the dimensionality of the -/// feature vector and is therefore equal to 'srn'. +// Assign each data point to one of k clusters using an expectation-maximization algorithm. +// k gives the number of clusters to identify +// Each column of sp[ srn, scn ] contains a multidimensional data point. +// srn therefore defines the dimensionality of the data. +// Each column of centroidV[ srn, k ] is set to the centroid of each of k clusters. +// classIdxV[ scn ] assigns the index (0 to k-1) of a cluster to each soure data point +// The function returns the number of iterations required for the EM process to converge. +// selIdxV[ scn ] is optional and contains a list of id's assoc'd with each column of sM. +// selKey is a integer value. +// If selIdxV is non-NULL then only columns of sM[] where selIdxV[] == selKey will be clustered. +// All columns of sM[] where the associated column in selIdxV[] do not match will be ignored. +// Set 'initFromCentroidFl' to true if the initial centroids should be taken from centroidM[]. +// otherwise the initial centroids are selected from 'k' random data points in sp[]. +// The distance function distFunc(cV,dV,dN) is called to determine the distance from a +// centroid the centroid 'cV[dN]' to a data point 'dV[dN]'. 'dN' is the dimensionality of the +// feature vector and is therefore equal to 'srn'. unsigned VECT_OP_FUNC(Kmeans)( unsigned* classIdxV, VECT_OP_TYPE* centroidM, @@ -543,9 +635,9 @@ unsigned VECT_OP_FUNC(Kmeans)( VECT_OP_TYPE (*distFunc)( void* userPtr, const VECT_OP_TYPE* cV, const VECT_OP_TYPE* dV, unsigned dN ), void* userDistPtr ); -/// 'srcFunc() should return NULL if the data point located at 'frmIdx' should not be included in the clustering. -/// Clustering is considered to be complete after 'maxIterCnt' iterations or when -/// 'deltaStopCnt' or fewer data points change class on a single iteration +// 'srcFunc() should return NULL if the data point located at 'frmIdx' should not be included in the clustering. +// Clustering is considered to be complete after 'maxIterCnt' iterations or when +// 'deltaStopCnt' or fewer data points change class on a single iteration unsigned VECT_OP_FUNC(Kmeans2)( unsigned* classIdxV, // classIdxV[scn] - data point class assignments VECT_OP_TYPE* centroidM, // centroidM[srn,K] - cluster centroids @@ -559,64 +651,67 @@ unsigned VECT_OP_FUNC(Kmeans2)( int iterCnt, // max. number of iterations (-1 to ignore) int deltaStopCnt); // if less than deltaStopCnt data points change classes on a given iteration then convergence occurs. -/// Evaluate the univariate normal distribution defined by 'mean' and 'stdDev'. -VECT_OP_TYPE* VECT_OP_FUNC(GaussPDF)( VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp, VECT_OP_TYPE mean, VECT_OP_TYPE stdDev ); - -/// Evaluate a multivariate normal distribution defined by meanV[D] and covarM[D,D] -/// at the data points held in the columns of xM[D,N]. Return the evaluation -/// results in the vector yV[N]. D is the dimensionality of the data. N is the number of -/// data points to evaluate and values to return in yV[N]. -/// Set diagFl to true if covarM is diagonal. -/// The function fails and returns false if the covariance matrix is singular. -bool VECT_OP_FUNC(MultVarGaussPDF)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* covarM, unsigned D, unsigned N, bool diagFl ); - -/// Same as multVarGaussPDF[] except takes the inverse covar mtx invCovarM[D,D] -/// and log determinant of covar mtx. -/// Always returns yV[]. -VECT_OP_TYPE* VECT_OP_FUNC(MultVarGaussPDF2)( VECT_OP_TYPE* yV, const VECT_OP_TYPE* xM, const VECT_OP_TYPE* meanV, const VECT_OP_TYPE* invCovarM, VECT_OP_TYPE logDet, unsigned D, unsigned N, bool diagFl ); - -/// Same as multVarGaussPDF[] except uses a function to obtain the data vectors. -/// srcFunc() can filter the data points by returning NULL if the data vector at frmIdx should -/// not be evaluated against the PDF. In this case yV[frmIdx] will be set to 0. -VECT_OP_TYPE* VECT_OP_FUNC(MultVarGaussPDF3)( - VECT_OP_TYPE* yV, - const VECT_OP_TYPE* (*srcFunc)(void* funcDataPtr, unsigned frmIdx ), - void* funcDataPtr, - const VECT_OP_TYPE* meanV, - const VECT_OP_TYPE* invCovarM, - VECT_OP_TYPE logDet, - unsigned D, - unsigned N, - bool diagFl ); - -/// Determine the most likely state sequece stateV[timeN] given a -/// transition matrix a[stateN,stateN], -/// observation probability matrix b[stateN,timeN] and -/// initial state probability vector phi[stateN]. -/// a[i,j] is the probability of transitioning from state i to state j. -/// b[i,t] is the probability of state i emitting the obj t. +// Determine the most likely state sequece stateV[timeN] given a +// transition matrix a[stateN,stateN], +// observation probability matrix b[stateN,timeN] and +// initial state probability vector phi[stateN]. +// a[i,j] is the probability of transitioning from state i to state j. +// b[i,t] is the probability of state i emitting the obj t. void VECT_OP_FUNC(DiscreteViterbi)(unsigned* stateV, unsigned timeN, unsigned stateN, const VECT_OP_TYPE* phi, const VECT_OP_TYPE* a, const VECT_OP_TYPE* b ); -/// Clip the line defined by x0,y0 to x1,y1 into the rect defined by xMin,yMin xMax,yMax. +//====================================================================================================================== +//) + +//( { label:"Graphics" desc:"Graphics related algorithms." kw:[vop] } + +// Generate the set of coordinates which describe a circle with a center at x,y. +// dbp[dn,2] must contain 2*dn elements. The first column holds the x coord and and the second holds the y coord. +VECT_OP_TYPE* VECT_OP_FUNC(CircleCoords)( VECT_OP_TYPE* dbp, unsigned dn, VECT_OP_TYPE x, VECT_OP_TYPE y, VECT_OP_TYPE varX, VECT_OP_TYPE varY ); + +// Clip the line defined by x0,y0 to x1,y1 into the rect defined by xMin,yMin xMax,yMax. bool VECT_OP_FUNC(ClipLine)( VECT_OP_TYPE* x0, VECT_OP_TYPE* y0, VECT_OP_TYPE* x1, VECT_OP_TYPE* y1, VECT_OP_TYPE xMin, VECT_OP_TYPE yMin, VECT_OP_TYPE xMax, VECT_OP_TYPE yMax ); -/// Return true if the line defined by x0,y0 to x1,y1 intersects with -/// the rectangle formed by xMin,yMin - xMax,yMax +// Return true if the line defined by x0,y0 to x1,y1 intersects with +// the rectangle formed by xMin,yMin - xMax,yMax bool VECT_OP_FUNC(IsLineInRect)( VECT_OP_TYPE x0, VECT_OP_TYPE y0, VECT_OP_TYPE x1, VECT_OP_TYPE y1, VECT_OP_TYPE xMin, VECT_OP_TYPE yMin, VECT_OP_TYPE xMax, VECT_OP_TYPE yMax ); -/// Return the perpendicular distance from the line formed by x0,y0 and x1,y1 -/// and the point px,py +// Return the perpendicular distance from the line formed by x0,y0 and x1,y1 +// and the point px,py VECT_OP_TYPE VECT_OP_FUNC(PtToLineDistance)( VECT_OP_TYPE x0, VECT_OP_TYPE y0, VECT_OP_TYPE x1, VECT_OP_TYPE y1, VECT_OP_TYPE px, VECT_OP_TYPE py); -/// Calculate the best fit line: b0 + b1*x_i through the points x_i,y_i. -/// Set x to NULL if it uses sequential integers [0,1,2,3...] -void VECT_OP_FUNC(Lsq1)(const VECT_OP_TYPE* x, const VECT_OP_TYPE* y, unsigned n, VECT_OP_TYPE* b0, VECT_OP_TYPE* b1 ); +//====================================================================================================================== +//) + +//( { label:"Miscellaneous DSP" desc:"Common DSP algorithms." kw:[vop] } + +// Compute the complex transient detection function from successive spectral frames. +// The spectral magntidue mag0V precedes mag1V and the phase (radians) spectrum phs0V precedes the phs1V which precedes phs2V. +// binCnt gives the length of each of the spectral vectors. +VECT_OP_TYPE VECT_OP_FUNC(ComplexDetect)(const VECT_OP_TYPE* mag0V, const VECT_OP_TYPE* mag1V, const VECT_OP_TYPE* phs0V, const VECT_OP_TYPE* phs1V, const VECT_OP_TYPE* phs2V, unsigned binCnt ); + +// Compute a set of DCT-II coefficients. Result dp[ coeffCnt, filtCnt ] +VECT_OP_TYPE* VECT_OP_FUNC(DctMatrix)( VECT_OP_TYPE* dp, unsigned coeffCnt, unsigned filtCnt ); -/// Given the points x0[xy0N],y0[xy0N] fill y1[i] with the interpolated value of y0[] at -/// x1[i]. Note that x0[] and x1[] must be increasing monotonic. -/// This function is similar to the octave interp1() function. +// Set the indexes of local peaks greater than threshold in dbp[]. +// Returns the number of peaks in dbp[] +// The maximum number of peaks from n source values is max(0,floor((n-1)/2)). +// Note that peaks will never be found at index 0 or index sn-1. +unsigned VECT_OP_FUNC(PeakIndexes)( unsigned* dbp, unsigned dn, const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE threshold ); + +// Return the index of the bin containing v otherwise return kInvalidIdx if v is below sbp[0] or above sbp[ n-1 ] +// The bin limits are contained in sbp[]. +// The value in spb[] are therefore expected to be in increasing order. +// The value returned will be in the range 0:sn-1. +unsigned VECT_OP_FUNC(BinIndex)( const VECT_OP_TYPE* sbp, unsigned sn, VECT_OP_TYPE v ); + + +// Given the points x0[xy0N],y0[xy0N] fill y1[i] with the interpolated value of y0[] at +// x1[i]. Note that x0[] and x1[] must be increasing monotonic. +// This function is similar to the octave interp1() function. void VECT_OP_FUNC(Interp1)(VECT_OP_TYPE* y1, const VECT_OP_TYPE* x1, unsigned xy1N, const VECT_OP_TYPE* x0, const VECT_OP_TYPE* y0, unsigned xy0N ); +//====================================================================================================================== +//) From ae1384784b120b2139201dcea97fa6e90c54a352 Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 11:59:58 -0400 Subject: [PATCH 3/8] Added 'doc' directory to hold document generation files. --- doc/cdg_cfg.json | 107 +++++++++++++++++++++++++ doc/cdg_code.css | 30 +++++++ doc/cdg_code_prefix.html | 13 +++ doc/cdg_code_suffix.html | 3 + doc/cdg_div_cod.css | 24 ++++++ doc/cdg_edoc.css | 106 +++++++++++++++++++++++++ doc/cdg_ext_anch.json | 6 ++ doc/gen_doc.sh | 28 +++++++ doc/libcm.pd | 102 ++++++++++++++++++++++++ doc/style.css | 166 +++++++++++++++++++++++++++++++++++++++ 10 files changed, 585 insertions(+) create mode 100755 doc/cdg_cfg.json create mode 100644 doc/cdg_code.css create mode 100755 doc/cdg_code_prefix.html create mode 100755 doc/cdg_code_suffix.html create mode 100644 doc/cdg_div_cod.css create mode 100755 doc/cdg_edoc.css create mode 100755 doc/cdg_ext_anch.json create mode 100755 doc/gen_doc.sh create mode 100755 doc/libcm.pd create mode 100755 doc/style.css diff --git a/doc/cdg_cfg.json b/doc/cdg_cfg.json new file mode 100755 index 0000000..67856c1 --- /dev/null +++ b/doc/cdg_cfg.json @@ -0,0 +1,107 @@ +{ + cfg : + { + // All paths and file names that do not begin with a '/' + // are prepended with the directory of this configuration + // file. + // + // If the last char in an 'in_dir' or 'excl_dir' path is NOT a '/' + // then the path represents all paths rooted on the given path. + // If the last char is a '/' then only the explicit path is + // used. + + // Note:if the last char in an input director path is a '/' then do not recurse + in_dir: [ "../src/" "../src/app" "../src/dsp" ] + excl_dir: [ ] + + edoc_fn: [ "libcm.pd" ] + html_prefix: "cdg_code_prefix.html" + html_suffix: "cdg_code_suffix.html" + anchor_fn: "cdg_ext_anch.json" + out_dir: "html" + + vc_prefix: [ + ["/home/kevin/src/libcm/doc/../src","https://gitea.currawongproject.org/cml/libcm/src/branch/master/src"] + ] + + + pandoc_exec: "/home/kevin/.local/bin/pandoc" + + // Only files with these extenstions will be processed. + file_ext: [ "h","c" ] + + // Exclude the following labels as anchor candidates. + anchor_excl: [ "foo", "label", "anchor" ] + + // Set 'true' to report comments that are not attached to + // structural elements. + rptFloatCmmtFl: false + + // Report if a 'ctag' generated tag could not be found. + rptMissingTagsFl: false + + // Report processed files + rptProcFilesFl: false + + // Report missing H files + rptMissingHFilesFl: true + + // Report missing C files + rptMissingCFilesFl: false + + // Report duplicate anchors. + rptDuplAnchorsFl: false + + // Maximum character count of output HTML lines + htmlMaxLineLength: 200 + + // Wrap Long Functions + wrapFunctionsFl: false + + // Preserve space + preserveSpaceFl: true + + // Link to field names + linkToFieldNamesFl: false + + // Use the external anchor files from ./cdg + usePrefExtAnchorFl: false + + // Run the edoc files through pandoc + runFinalPandocFl: true + + // Treat all selected files which do not have block + // markers as though they are wrapped in block markers. + promiscuousModeFl: false + + keyword_index: + [ + [ base "Foundation classes and API's"] + [ real_time "Real-time system classes and API's"] + ] + + pandoc_args: + [ + "-fmarkdown" + "-thtml5" + "--css" + "cdg_div_cod.css" + "--css" + "cdg_edoc.css" + "--css" + "style.css" + "--toc" + "--standalone" + "--number-sections" + ] + + copy_files: + [ + "cdg_div_cod.css" + "cdg_edoc.css" + "cdg_code.css" + "style.css" + ] + + } +} diff --git a/doc/cdg_code.css b/doc/cdg_code.css new file mode 100644 index 0000000..a10e708 --- /dev/null +++ b/doc/cdg_code.css @@ -0,0 +1,30 @@ + +td.linenos { background-color: #fffff0; padding-right: 10px; } +span.lineno { background-color: #fffff0; padding: 0 5px 0 5px; } +pre { line-height: 135%; } +body .hll { background-color: #ffffff; } +body { background: #f8f8f8; } +body .c { color: firebrick; font-style: italic; } /* Comment */ +body .k { color: #008000; font-weight: normal; } /* Keyword.Reserved */ +body .p { color: #666666; } /* Operator */ +body .f { color: #0000ff; font-weight: normal; } /* Function */ +body .e { color: #0000ff; font-weight: normal; } /* enum */ +body .m { color: #008000; font-weight: normal; } /* macro */ +body .t { color: #008000; font-weight: normal; } /* typedef */ +body .i { color: #0000ff; font-weight: normal; } /* ident */ +body .l { color: #660066; } /* Literal */ +body .u { color: #000000; } +body .a { + border: 1px dotted gray; + background-color: #ececec; + color: #1111111; + padding: 0.5em; +} + +#hr1 { height: 1; color:#000000; background-color: #ff0000; } +#hr2 { height: 4; color:#000000; background-color: #ff0000; } + +.blk_title { + font-wieght: bold; + font-size: 120%; +} diff --git a/doc/cdg_code_prefix.html b/doc/cdg_code_prefix.html new file mode 100755 index 0000000..c2c3661 --- /dev/null +++ b/doc/cdg_code_prefix.html @@ -0,0 +1,13 @@ + + + + + + + + + + + + +
diff --git a/doc/cdg_code_suffix.html b/doc/cdg_code_suffix.html new file mode 100755 index 0000000..9943ff0 --- /dev/null +++ b/doc/cdg_code_suffix.html @@ -0,0 +1,3 @@ +
+ + diff --git a/doc/cdg_div_cod.css b/doc/cdg_div_cod.css new file mode 100644 index 0000000..bff2ba6 --- /dev/null +++ b/doc/cdg_div_cod.css @@ -0,0 +1,24 @@ + + +.cod pre .c { color: firebrick; font-weight: normal; } /* Comment */ +.cod pre .k { color: #008000; font-weight: normal; } /* Keyword.Reserved */ +.cod pre .p { color: #666666 } /* Operator */ +.cod pre .f { color: #000000; font-weight: normal; } /* Function */ +.cod pre .e { color: #000000; font-weight: normal; } /* enum */ +.cod pre .m { color: #008000; font-weight: normal; } /* macro */ +.cod pre .t { color: #008000; font-weight: normal; } /* typedef */ +.cod pre .i { color: #000000; font-weight: normal; } /* ident */ +.cod pre .l { color: #660066 } /* Literal */ +.cod pre .u { color: #000000 } + +.cod pre a:link {text-decoration:none; font-weight:500; } +.cod pre a:visited {text-decoration:none; font-weight:500; } +.cod pre a:hover {text-decoration:none; font-weight:700; } + +/* embedded pandoc comments */ +.cod pre .a { + border: 1px dotted gray; + background-color: #ececec; + color: #1111111; + padding: 0.5em; +} diff --git a/doc/cdg_edoc.css b/doc/cdg_edoc.css new file mode 100755 index 0000000..f192cd9 --- /dev/null +++ b/doc/cdg_edoc.css @@ -0,0 +1,106 @@ +body { + margin: auto; + padding-right: 1em; + padding-left: 1em; + max-width: 44em; + border-left: 1px solid black; + border-right: 1px solid black; + color: black; + font-family: Verdana, sans-serif; + font-size: 100%; + line-height: 140%; + color: #333; +} +pre { + border: 1px dotted gray; + background-color: #ececec; + color: #1111111; + padding: 0.5em; +} +code { + font-family: monospace; + line-height: 115% +} +h1 a, h2 a, h3 a, h4 a, h5 a { + text-decoration: none; + color: #424242; +} +h1, h2, h3, h4, h5 { font-family: verdana; + font-weight: bold; + color: #424242; } +h1 { + font-size: 150%; + border-bottom: 3px solid black; +} + +h2 { + font-size: 110%; + border-bottom: 1px solid black; +} + +h3 { + font-size: 90%; + border-bottom: 1px dotted black; + +} + +h4 { + font-size: 80%; + font-style: italic; +} + +h5 { + font-size: 80%; + font-style: italic; +} + +table { + width: 100%; + background-color: #acacac; + text-align:left; +} + +table .odd { + background-color: #fcfcfc; +} + +table .even { + background-color: #ececec; +} + + +h1.title { + font-size: 200%; + font-weight: bold; + padding-top: 0.2em; + padding-bottom: 0.2em; + text-align: left; + border: none; +} + +dt code { + font-weight: bold; +} +dd p { + margin-top: 0; +} + +#footer { + padding-top: 1em; + font-size: 70%; + color: gray; + text-align: center; + } + +/* specify the height of example blocks (
's inside of 
) */ +.cod pre +{ + line-height: 115%; +} + +/* control the kw index label column width */ +.kw_label_col { + width:200px; + max-width:200px; + min-width:200px; +} diff --git a/doc/cdg_ext_anch.json b/doc/cdg_ext_anch.json new file mode 100755 index 0000000..1230ad4 --- /dev/null +++ b/doc/cdg_ext_anch.json @@ -0,0 +1,6 @@ +{ + anchors: + [ + { label: "Pandoc" anchor:"http://johnmacfarlane.net/pandoc/README.html" } + ] +} diff --git a/doc/gen_doc.sh b/doc/gen_doc.sh new file mode 100755 index 0000000..c126948 --- /dev/null +++ b/doc/gen_doc.sh @@ -0,0 +1,28 @@ + +# switches: -E : Stop after preprocess +# -C : Do not strip comments. +# -P : Do not generate line markers +# -traditional-cpp : preserve white space + +# run the pre-processor to generate the vector ops documentation +gcc -E -C -P -traditional-cpp -o temp.h ../src/vop/cmVectOpsDoc.h + +# The --traditional-cpp switch prevents the 'stringizing' +# C pre-proc direcive from working this leaves '##_' tokens +# which need to be replaced by '_' +# replace '_##` with '_' +sed 's/\(_##\)/_/g' temp.h > temp1.h + +# Remove header text generated by gcc. +# sed '/\/\*/,/\/\/end_cut/{#!d}' temp.h +sed '/\/\*/,/\/\/end_cut/{//!d;};' temp1.h > temp2.h + +# Remove the first two lines. +tail -n +3 temp2.h > ../src/cmVectOpsDocOut.h + +rm -f temp.h +rm -f temp1.h +rm -f temp2.h + +# Run the doc generator +#cdg -c cdg_cfg.json -o ~/temp/doc_libcm diff --git a/doc/libcm.pd b/doc/libcm.pd new file mode 100755 index 0000000..2f04600 --- /dev/null +++ b/doc/libcm.pd @@ -0,0 +1,102 @@ +% _libcm_ Reference Documentation +% + +Prerequisites: +============== + +Fedora: +`sudo dnf install fftw fftw-devel atlas atlas-devel alsa-lib alsa-lib-devel` + + + +_cm_ Classes And API's +====================== + +### Foundation classes used throughout the _cm_ library. + +{$cdg_kw_list_cdg base} + +### Audio related classes. + +{$cdg_kw_list_cdg audio} + +### MIDI related classes. + +{$cdg_kw_list_cdg midi} + +### File readers and writers. +{$cdg_kw_list_cdg file} + +### Text processing related classes. +{$cdg_kw_list_cdg text} + +### Container related classes. +{$cdg_kw_list_cdg container} + +### Math related classes. +{$cdg_kw_list_cdg math} + +### Vector operations +{$cdg_kw_list_cdg vop} + +### Multi-threading and parallel processing. +{$cdg_kw_list_cdg parallel} + +### Data network related classes. +{$cdg_kw_list_cdg network} + +### Operating system interface classes. +{$cdg_kw_list_cdg system} + +### Clock and time related classes. +{$cdg_kw_list_cdg time} + +### Real-time processing related classes +{$cdg_kw_list_cdg rt} + +### Signal analysis related classes +{$cdg_kw_list_cdg analysis} + +### Plotting related classes. +{$cdg_kw_list_cdg plot} + +### Demo functions. +{$cdg_kw_list_cdg demo} + +### 'proc' library modules. +{$cdg_kw_list_cdg proclib} + +### 'proc' classes. +{$cdg_kw_list_cdg proc} + +### Modeling related classes. +{$cdg_kw_list_cdg model} + +### Improved real-time system. +{$cdg_kw_list_cdg rtsys} + +### _fluxo_ related classes. +{$cdg_kw_list_cdg fluxo} + +### _GUTIM_ related classes. +{$cdg_kw_list_cdg gutim} + +### Musical score related classes +{$cdg_kw_list_cdg score} + +### Sequencer related classes +{$cdg_kw_list_cdg seq} + +### Dataflow system classes. +{$cdg_kw_list_cdg snap} + +### Dataflow processesing units. +{$cdg_kw_list_cdg sunit} + +### Dataflow built-in programs +{$cdg_kw_list_cdg spgm} + +File List +========= + +{$cdg_file_list_cdg} diff --git a/doc/style.css b/doc/style.css new file mode 100755 index 0000000..280bd4b --- /dev/null +++ b/doc/style.css @@ -0,0 +1,166 @@ +body { + margin: auto; + padding-right: 1em; + padding-left: 1em; + max-width: 55em; + border-left: 1px solid black; + border-right: 1px solid black; + color: black; + background: #F8F5EC; + font-family: Arial, Helvetica, sans-serif; + font-size: 90%; + font-weight: normal + line-height: 100%; + + color: #333333; +} +pre { + border: 1px dotted gray; + background-color: #ececec; + color: #1111111; + padding: 0.5em; +} +code { + font-family: monospace; + line-height: 100%; +} +h1 a, h2 a, h3 a, h4 a, h5 a { + text-decoration: none; + color: #660000; +} +h1, h2, h3, h4, h5 { font-family: verdana; + font-weight: bold; + color: #660000; } +h1 { + font-size: 100%; + border-bottom: 1px solid black; +} + +h2 { + font-size: 100%; + color:$660000; + +} + +h3 { + font-size: 95%; +} + +h4 { + font-size: 90%; + font-style: italic; +} + +h5 { + font-size: 90%; + font-style: italic; +} + +h1.title { + font-size: 200%; + font-weight: bold; + padding-top: 0.2em; + padding-bottom: 0.2em; + text-align: left; + border: none; +} + +dt code { + font-weight: bold; +} +dd p { + margin-top: 0; +} + +#footer { + padding-top: 1em; + font-size: 70%; + color: gray; + text-align: center; +} + +table { + width: 100%; + background-color: #acacac; + text-align:left; +} + +table .odd { + background-color: #f7f7f7; +} + +table .even { + background-color: #ececec; +} + +a:link { color:inherit; font-weight:bold; text-decoration: none; } +a:active { color:inherit; font-weight:bold; text-decoration: none; } +a:visited { color:inherit; font-weight:bold; text-decoration: none; } +a:hover { color:inherit; font-weight:bold; text-decoration: none; } + +td.linenos { background-color: #f0f0f0; padding-right: 10px; } +span.lineno { background-color: #f0f0f0; padding: 0 5px 0 5px; } +pre { line-height: 125%; } +span.hll { background-color: #ffffcc } + +span.c { color: #008800; font-style: italic } /* Comment */ +span.err { border: 1px solid #FF0000 } /* Error */ +span.k { color: #AA22FF; font-weight: normal } /* Keyword */ +span.o { color: #666666 } /* Operator */ +span.cm { color: #FF0000; font-style: italic } /* Comment.Multiline */ +span.cp { color: #8000FF } /* Comment.Preproc */ +span.c1 { color: #FF0000; font-style: italic } /* Comment.Single */ +span.cs { color: #FF0000; font-weight: bold } /* Comment.Special */ +span.gd { color: #A00000 } /* Generic.Deleted */ +span.ge { font-style: italic } /* Generic.Emph */ +span.gr { color: #FF0000 } /* Generic.Error */ +span.gh { color: #000080; font-weight: bold } /* Generic.Heading */ +span.gi { color: #00A000 } /* Generic.Inserted */ +span.go { color: #808080 } /* Generic.Output */ +span.gp { color: #000080; font-weight: bold } /* Generic.Prompt */ +span.gs { font-weight: bold } /* Generic.Strong */ +span.gu { color: #800080; font-weight: bold } /* Generic.Subheading */ +span.gt { color: #0040D0 } /* Generic.Traceback */ +span.kc { color: #AA22FF; font-weight: bold } /* Keyword.Constant */ +span.kd { color: #AA22FF; font-weight: bold } /* Keyword.Declaration */ +span.kn { color: #AA22FF; font-weight: bold } /* Keyword.Namespace */ +span.kp { color: #AA22FF } /* Keyword.Pseudo */ +span.kr { color: #008800; font-weight: normal } /* Keyword.Reserved */ +span.kt { color: #008800; font-weight: normal } /* Keyword.Type */ +span.m { color: #666666 } /* Literal.Number */ +span.s { color: #BB4444 } /* Literal.String */ +span.na { color: #BB4444 } /* Name.Attribute */ +span.nb { color: #AA22FF } /* Name.Builtin */ +span.nc { color: #0000FF } /* Name.Class */ +span.no { color: #DF3A01 } /* Name.Constant */ +span.nd { color: #AA22FF } /* Name.Decorator */ +span.ni { color: #999999; font-weight: bold } /* Name.Entity */ +span.ne { color: #D2413A; font-weight: bold } /* Name.Exception */ +span.nf { color: #0000FF } /* Name.Function */ +span.nl { color: #A0A000 } /* Name.Label */ +span.nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ +span.nt { color: #008000; font-weight: bold } /* Name.Tag */ +span.nv { color: #B8860B } /* Name.Variable */ +span.ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ +span.w { color: #bbbbbb } /* Text.Whitespace */ +span.mf { color: #666666 } /* Literal.Number.Float */ +span.mh { color: #666666 } /* Literal.Number.Hex */ +span.mi { color: #666666 } /* Literal.Number.Integer */ +span.mo { color: #666666 } /* Literal.Number.Oct */ +span.sb { color: #BB4444 } /* Literal.String.Backtick */ +span.sc { color: #BB4444 } /* Literal.String.Char */ +span.sd { color: #BB4444; font-style: italic } /* Literal.String.Doc */ +span.s2 { color: #BB4444 } /* Literal.String.Double */ +span.se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */ +span.sh { color: #BB4444 } /* Literal.String.Heredoc */ +span.si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */ +span.sx { color: #008000 } /* Literal.String.Other */ +span.sr { color: #BB6688 } /* Literal.String.Regex */ +span.s1 { color: #BB4444 } /* Literal.String.Single */ +span.ss { color: #B8860B } /* Literal.String.Symbol */ +span.bp { color: #AA22FF } /* Name.Builtin.Pseudo */ +span.vc { color: #B8860B } /* Name.Variable.Class */ +span.vg { color: #B8860B } /* Name.Variable.Global */ +span.vi { color: #B8860B } /* Name.Variable.Instance */ +span.il { color: #666666 } /* Literal.Number.Integer.Long */ + From 05cd76192e9bf69774ef15730d18d54a3c142596 Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 12:00:08 -0400 Subject: [PATCH 4/8] .gitignore updated. --- .gitignore | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.gitignore b/.gitignore index badd313..65d9b9c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,22 @@ +*.o +*.lo +*.Plo + +build/linux/debug/include +build/linux/debug/lib +build/linux/debug/src + +build/linux/release/include +build/linux/release/lib +build/linux/release/src + +Makefile +config.h +config.log +config.status +libtool +stamp-h1 + Makefile.in .DS_Store aclocal.m4 From fd3db429d2894aaa2f345f1542f596bdaba138d9 Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 15:40:25 -0400 Subject: [PATCH 5/8] Apply a license notice to all source code files. Add the LICENSE and COPYING files. --- COPYING | 674 +++++++++++++++++++++++++++++ LICENSE | 12 + src/app/cmDspPgmJsonToDot.c | 2 + src/app/cmDspPgmJsonToDot.h | 2 + src/app/cmMidiScoreFollow.c | 2 + src/app/cmMidiScoreFollow.h | 2 + src/app/cmOnset.c | 2 + src/app/cmOnset.h | 2 + src/app/cmPickup.c | 2 + src/app/cmPickup.h | 2 + src/app/cmScore.c | 2 + src/app/cmScore.h | 2 + src/app/cmScoreMatchGraphic.c | 2 + src/app/cmScoreMatchGraphic.h | 2 + src/app/cmScoreProc.c | 2 + src/app/cmScoreProc.h | 2 + src/app/cmSdb.c | 2 + src/app/cmSdb.h | 2 + src/app/cmTakeSeqBldr.c | 2 + src/app/cmTakeSeqBldr.h | 2 + src/app/cmTimeLine.c | 2 + src/app/cmTimeLine.h | 2 + src/app/cmXScore.c | 2 + src/app/cmXScore.h | 2 + src/cmApBuf.c | 2 + src/cmApBuf.h | 2 + src/cmArray.c | 2 + src/cmArray.h | 2 + src/cmAudDsp.c | 2 + src/cmAudDsp.h | 2 + src/cmAudDspIF.c | 2 + src/cmAudDspIF.h | 2 + src/cmAudDspLocal.c | 2 + src/cmAudDspLocal.h | 2 + src/cmAudLabelFile.c | 2 + src/cmAudLabelFile.h | 2 + src/cmAudioAggDev.c | 2 + src/cmAudioAggDev.h | 2 + src/cmAudioBuf.c | 2 + src/cmAudioBuf.h | 2 + src/cmAudioFile.c | 2 + src/cmAudioFile.h | 2 + src/cmAudioFileDev.c | 2 + src/cmAudioFileDev.h | 2 + src/cmAudioFileMgr.c | 2 + src/cmAudioFileMgr.h | 2 + src/cmAudioNrtDev.c | 2 + src/cmAudioNrtDev.h | 2 + src/cmAudioPort.c | 2 + src/cmAudioPort.h | 2 + src/cmAudioPortFile.c | 2 + src/cmAudioPortFile.h | 2 + src/cmAudioSys.c | 2 + src/cmAudioSys.h | 2 + src/cmAudioSysMsg.h | 2 + src/cmComplexTypes.c | 2 + src/cmComplexTypes.h | 2 + src/cmCsv.c | 2 + src/cmCsv.h | 2 + src/cmCtx.c | 2 + src/cmCtx.h | 2 + src/cmDList.c | 2 + src/cmDList.h | 2 + src/cmDListTpl.h | 2 + src/cmData.c | 2 + src/cmData.h | 2 + src/cmDevCfg.c | 2 + src/cmDevCfg.h | 2 + src/cmErr.c | 2 + src/cmErr.h | 2 + src/cmExec.c | 2 + src/cmExec.h | 2 + src/cmFeatFile.c | 2 + src/cmFeatFile.h | 2 + src/cmFile.c | 2 + src/cmFile.h | 2 + src/cmFileSys.c | 2 + src/cmFileSys.h | 2 + src/cmFloatTypes.h | 2 + src/cmFrameFile.c | 2 + src/cmFrameFile.h | 2 + src/cmGlobal.c | 2 + src/cmGlobal.h | 2 + src/cmGnuPlot.c | 2 + src/cmGnuPlot.h | 2 + src/cmGr.c | 2 + src/cmGr.h | 2 + src/cmGrDevCtx.c | 2 + src/cmGrDevCtx.h | 2 + src/cmGrPage.c | 2 + src/cmGrPage.h | 2 + src/cmGrPlot.c | 2 + src/cmGrPlot.h | 2 + src/cmGrPlotAudio.c | 2 + src/cmGrPlotAudio.h | 2 + src/cmHashTbl.c | 2 + src/cmHashTbl.h | 2 + src/cmJson.c | 2 + src/cmJson.h | 2 + src/cmKeyboard.c | 2 + src/cmKeyboard.h | 2 + src/cmLex.c | 2 + src/cmLex.h | 2 + src/cmLib.c | 2 + src/cmLib.h | 2 + src/cmLinkedHeap.c | 2 + src/cmLinkedHeap.h | 2 + src/cmMain.c | 2 + src/cmMallocDebug.c | 2 + src/cmMallocDebug.h | 2 + src/cmMath.c | 2 + src/cmMath.h | 2 + src/cmMem.c | 2 + src/cmMem.h | 2 + src/cmMidi.c | 2 + src/cmMidi.h | 2 + src/cmMidiFile.c | 2 + src/cmMidiFile.h | 2 + src/cmMidiFilePlay.c | 2 + src/cmMidiFilePlay.h | 2 + src/cmMidiPort.c | 2 + src/cmMidiPort.h | 2 + src/cmMsgProtocol.c | 2 + src/cmMsgProtocol.h | 2 + src/cmPP_NARG.h | 2 + src/cmPgmOpts.c | 2 + src/cmPgmOpts.h | 2 + src/cmPrefix.h | 2 + src/cmPrefs.c | 2 + src/cmPrefs.h | 2 + src/cmProc.c | 2 + src/cmProc.h | 2 + src/cmProc2.c | 2 + src/cmProc2.h | 2 + src/cmProc3.c | 2 + src/cmProc3.h | 2 + src/cmProc4.c | 2 + src/cmProc4.h | 2 + src/cmProc5.c | 2 + src/cmProc5.h | 2 + src/cmProcObj.c | 2 + src/cmProcObj.h | 2 + src/cmProcTest.c | 2 + src/cmProcTest.h | 2 + src/cmRbm.c | 2 + src/cmRbm.h | 2 + src/cmRpt.c | 2 + src/cmRpt.h | 2 + src/cmRptFile.c | 2 + src/cmRptFile.h | 2 + src/cmRtNet.c | 2 + src/cmRtNet.h | 2 + src/cmRtSys.c | 2 + src/cmRtSys.h | 2 + src/cmRtSysMsg.h | 2 + src/cmSerialPort.c | 2 + src/cmSerialPort.h | 2 + src/cmSerialize.c | 2 + src/cmSerialize.h | 2 + src/cmStack.c | 2 + src/cmStack.h | 2 + src/cmStrStream.c | 2 + src/cmStrStream.h | 2 + src/cmSvgWriter.c | 2 + src/cmSvgWriter.h | 2 + src/cmSymTbl.c | 2 + src/cmSymTbl.h | 2 + src/cmSyncRecd.c | 2 + src/cmSyncRecd.h | 2 + src/cmTagFile.c | 2 + src/cmTagFile.h | 2 + src/cmTaskMgr.c | 2 + src/cmTaskMgr.h | 2 + src/cmText.c | 2 + src/cmText.h | 2 + src/cmTextTemplate.c | 2 + src/cmTextTemplate.h | 2 + src/cmThread.c | 2 + src/cmThread.h | 2 + src/cmTime.c | 2 + src/cmTime.h | 2 + src/cmUdpNet.c | 2 + src/cmUdpNet.h | 2 + src/cmUdpPort.c | 2 + src/cmUdpPort.h | 2 + src/cmUi.c | 2 + src/cmUi.h | 2 + src/cmUiDrvr.c | 2 + src/cmUiDrvr.h | 2 + src/cmUiRtSysMstr.c | 2 + src/cmUiRtSysMstr.h | 2 + src/cmVectOpsDocOut.h | 2 + src/cmVirtNet.c | 2 + src/cmVirtNet.h | 2 + src/cmXml.c | 2 + src/cmXml.h | 2 + src/dsp/cmDspBuiltIn.c | 2 + src/dsp/cmDspBuiltIn.h | 2 + src/dsp/cmDspClass.c | 2 + src/dsp/cmDspClass.h | 2 + src/dsp/cmDspCtx.h | 2 + src/dsp/cmDspFx.c | 2 + src/dsp/cmDspFx.h | 2 + src/dsp/cmDspKr.c | 2 + src/dsp/cmDspKr.h | 2 + src/dsp/cmDspMod.c | 2 + src/dsp/cmDspNet.c | 2 + src/dsp/cmDspNet.h | 2 + src/dsp/cmDspPgm.c | 2 + src/dsp/cmDspPgm.h | 2 + src/dsp/cmDspPgmKr.c | 2 + src/dsp/cmDspPgmKr.h | 2 + src/dsp/cmDspPgmKrChain.c | 2 + src/dsp/cmDspPgmKrChain.h | 2 + src/dsp/cmDspPgmKrChain2.c | 2 + src/dsp/cmDspPgmKrTimeLineLite.c | 2 + src/dsp/cmDspPgmKrTimeLineLiteAf.c | 2 + src/dsp/cmDspPgmKrTksb.c | 2 + src/dsp/cmDspPgmPP.c | 2 + src/dsp/cmDspPgmPP.h | 2 + src/dsp/cmDspPgmPPMain.c | 2 + src/dsp/cmDspPgmPPMain.h | 2 + src/dsp/cmDspPreset.c | 2 + src/dsp/cmDspPreset.h | 2 + src/dsp/cmDspStore.c | 2 + src/dsp/cmDspStore.h | 2 + src/dsp/cmDspSys.c | 2 + src/dsp/cmDspSys.h | 2 + src/dsp/cmDspUi.c | 2 + src/dsp/cmDspUi.h | 2 + src/dsp/cmDspValue.c | 2 + src/dsp/cmDspValue.h | 2 + src/linux/cmAudioPortAlsa.c | 2 + src/linux/cmAudioPortAlsa.h | 2 + src/linux/cmFileSysLinux.c | 2 + src/linux/cmFileSysLinux.h | 2 + src/linux/cmMidiAlsa.c | 2 + src/osx/cmAudioPortOsx.c | 2 + src/osx/cmAudioPortOsx.h | 2 + src/osx/cmFileSysOsx.c | 2 + src/osx/cmFileSysOsx.h | 2 + src/osx/cmMidiOsx.c | 2 + src/sa/cmSaProc.c | 2 + src/sa/cmSaProc.h | 2 + src/vop/cmProcTemplate.c | 2 + src/vop/cmProcTemplate.h | 2 + src/vop/cmProcTemplateCode.h | 2 + src/vop/cmProcTemplateHdr.h | 2 + src/vop/cmProcTemplateMain.h | 2 + src/vop/cmProcTemplateUndef.h | 2 + src/vop/cmVectOps.c | 2 + src/vop/cmVectOps.h | 2 + src/vop/cmVectOpsDoc.h | 2 + src/vop/cmVectOpsRICode.h | 2 + src/vop/cmVectOpsRIHdr.h | 2 + src/vop/cmVectOpsTemplateCode.h | 2 + src/vop/cmVectOpsTemplateHdr.h | 2 + src/vop/cmVectOpsTemplateMain.h | 2 + src/vop/cmVectOpsTemplateUndef.h | 2 + 259 files changed, 1200 insertions(+) create mode 100644 COPYING create mode 100644 LICENSE diff --git a/COPYING b/COPYING new file mode 100644 index 0000000..f288702 --- /dev/null +++ b/COPYING @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..9440101 --- /dev/null +++ b/LICENSE @@ -0,0 +1,12 @@ +This library is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or (at +your option) any later version. + +This library is distributed in the hope that it will be useful, but +WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see . diff --git a/src/app/cmDspPgmJsonToDot.c b/src/app/cmDspPgmJsonToDot.c index d6c04e2..3203587 100644 --- a/src/app/cmDspPgmJsonToDot.c +++ b/src/app/cmDspPgmJsonToDot.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmDspPgmJsonToDot.h b/src/app/cmDspPgmJsonToDot.h index 59ab618..e2d5062 100644 --- a/src/app/cmDspPgmJsonToDot.h +++ b/src/app/cmDspPgmJsonToDot.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgmJsonToDot_h #define cmDspPgmJsonToDot_h diff --git a/src/app/cmMidiScoreFollow.c b/src/app/cmMidiScoreFollow.c index 1b32b67..681e1c1 100644 --- a/src/app/cmMidiScoreFollow.c +++ b/src/app/cmMidiScoreFollow.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/app/cmMidiScoreFollow.h b/src/app/cmMidiScoreFollow.h index 8796c20..57f9bff 100644 --- a/src/app/cmMidiScoreFollow.h +++ b/src/app/cmMidiScoreFollow.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMidiScoreFollow_h #define cmMidiScoreFollow_h diff --git a/src/app/cmOnset.c b/src/app/cmOnset.c index bb41c43..14e6f77 100644 --- a/src/app/cmOnset.c +++ b/src/app/cmOnset.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmComplexTypes.h" diff --git a/src/app/cmOnset.h b/src/app/cmOnset.h index 397d14e..22c54c3 100644 --- a/src/app/cmOnset.h +++ b/src/app/cmOnset.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmOnset_h #define cmOnset_h diff --git a/src/app/cmPickup.c b/src/app/cmPickup.c index 8536d1d..c360e3e 100644 --- a/src/app/cmPickup.c +++ b/src/app/cmPickup.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmPickup.h b/src/app/cmPickup.h index 13eff44..22729aa 100644 --- a/src/app/cmPickup.h +++ b/src/app/cmPickup.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmPickup_h #define cmPickup_h diff --git a/src/app/cmScore.c b/src/app/cmScore.c index 5850953..5471198 100644 --- a/src/app/cmScore.c +++ b/src/app/cmScore.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmScore.h b/src/app/cmScore.h index a2739df..4c9c84f 100644 --- a/src/app/cmScore.h +++ b/src/app/cmScore.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmScore_h #define cmScore_h diff --git a/src/app/cmScoreMatchGraphic.c b/src/app/cmScoreMatchGraphic.c index b013c97..568c1d7 100644 --- a/src/app/cmScoreMatchGraphic.c +++ b/src/app/cmScoreMatchGraphic.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmScoreMatchGraphic.h b/src/app/cmScoreMatchGraphic.h index 02258fc..79b0c58 100644 --- a/src/app/cmScoreMatchGraphic.h +++ b/src/app/cmScoreMatchGraphic.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmScoreMatchGraphic_h #define cmScoreMatchGraphic_h diff --git a/src/app/cmScoreProc.c b/src/app/cmScoreProc.c index 33aa4af..9de92af 100644 --- a/src/app/cmScoreProc.c +++ b/src/app/cmScoreProc.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/app/cmScoreProc.h b/src/app/cmScoreProc.h index 5cd1d65..2fc5c5f 100644 --- a/src/app/cmScoreProc.h +++ b/src/app/cmScoreProc.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmScoreProc_h #define cmScoreProc_h diff --git a/src/app/cmSdb.c b/src/app/cmSdb.c index 398977d..a8cd53a 100644 --- a/src/app/cmSdb.c +++ b/src/app/cmSdb.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/app/cmSdb.h b/src/app/cmSdb.h index f716c5b..a362eb9 100644 --- a/src/app/cmSdb.h +++ b/src/app/cmSdb.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSdb_h #define cmSdb_h diff --git a/src/app/cmTakeSeqBldr.c b/src/app/cmTakeSeqBldr.c index 61477cb..9d425b6 100644 --- a/src/app/cmTakeSeqBldr.c +++ b/src/app/cmTakeSeqBldr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmTakeSeqBldr.h b/src/app/cmTakeSeqBldr.h index 123c1da..ac93dec 100644 --- a/src/app/cmTakeSeqBldr.h +++ b/src/app/cmTakeSeqBldr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmTakeSeqBldr_h #define cmTakeSeqBldr_h diff --git a/src/app/cmTimeLine.c b/src/app/cmTimeLine.c index 2897353..6fd3b10 100644 --- a/src/app/cmTimeLine.c +++ b/src/app/cmTimeLine.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/app/cmTimeLine.h b/src/app/cmTimeLine.h index af3a29f..1f46ae6 100644 --- a/src/app/cmTimeLine.h +++ b/src/app/cmTimeLine.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmTimeLine_h #define cmTimeLine_h diff --git a/src/app/cmXScore.c b/src/app/cmXScore.c index 5892a42..0691bd8 100644 --- a/src/app/cmXScore.c +++ b/src/app/cmXScore.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/app/cmXScore.h b/src/app/cmXScore.h index b7bb049..0c36a63 100644 --- a/src/app/cmXScore.h +++ b/src/app/cmXScore.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmXScore_h #define cmXScore_h diff --git a/src/cmApBuf.c b/src/cmApBuf.c index 7036054..ef038fe 100644 --- a/src/cmApBuf.c +++ b/src/cmApBuf.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmApBuf.h b/src/cmApBuf.h index a0d91fe..e62a25c 100644 --- a/src/cmApBuf.h +++ b/src/cmApBuf.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( {file_desc: "Thread safe audio buffer class." kw:[rt audio]} // // This file defines an audio buffer class which handles diff --git a/src/cmArray.c b/src/cmArray.c index 961b3c1..ef5c497 100644 --- a/src/cmArray.c +++ b/src/cmArray.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmArray.h b/src/cmArray.h index 8cb9794..41f58ff 100644 --- a/src/cmArray.h +++ b/src/cmArray.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmArray_h #define cmArray_h diff --git a/src/cmAudDsp.c b/src/cmAudDsp.c index 213a7dd..f15ba14 100644 --- a/src/cmAudDsp.c +++ b/src/cmAudDsp.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudDsp.h b/src/cmAudDsp.h index 6e0c88b..29175ac 100644 --- a/src/cmAudDsp.h +++ b/src/cmAudDsp.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudDsp_h #define cmAudDsp_h diff --git a/src/cmAudDspIF.c b/src/cmAudDspIF.c index f938f1c..374d482 100644 --- a/src/cmAudDspIF.c +++ b/src/cmAudDspIF.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudDspIF.h b/src/cmAudDspIF.h index 9e4db3e..6ebc75e 100644 --- a/src/cmAudDspIF.h +++ b/src/cmAudDspIF.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudDspIF_h #define cmAudDspIF_h diff --git a/src/cmAudDspLocal.c b/src/cmAudDspLocal.c index 145027a..9f01135 100644 --- a/src/cmAudDspLocal.c +++ b/src/cmAudDspLocal.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudDspLocal.h b/src/cmAudDspLocal.h index d5abbba..5f0465d 100644 --- a/src/cmAudDspLocal.h +++ b/src/cmAudDspLocal.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudDspLocal_h #define cmAudDspLocal_h diff --git a/src/cmAudLabelFile.c b/src/cmAudLabelFile.c index 7ba1a3a..dfbef16 100644 --- a/src/cmAudLabelFile.c +++ b/src/cmAudLabelFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudLabelFile.h b/src/cmAudLabelFile.h index 1bc1db1..e77c920 100644 --- a/src/cmAudLabelFile.h +++ b/src/cmAudLabelFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudLabelFile_h #define cmAudLabelFile_h diff --git a/src/cmAudioAggDev.c b/src/cmAudioAggDev.c index 921d896..0846d7a 100644 --- a/src/cmAudioAggDev.c +++ b/src/cmAudioAggDev.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmAudioAggDev.h b/src/cmAudioAggDev.h index 58f5e02..22797d0 100644 --- a/src/cmAudioAggDev.h +++ b/src/cmAudioAggDev.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioAggDev_h #define cmAudioAggDev_h diff --git a/src/cmAudioBuf.c b/src/cmAudioBuf.c index 46f0149..dacc527 100644 --- a/src/cmAudioBuf.c +++ b/src/cmAudioBuf.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmAudioBuf.h b/src/cmAudioBuf.h index 18e1da1..dec1971 100644 --- a/src/cmAudioBuf.h +++ b/src/cmAudioBuf.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioBuf_h #define cmAudioBuf_h diff --git a/src/cmAudioFile.c b/src/cmAudioFile.c index 1a4da95..b1e8961 100644 --- a/src/cmAudioFile.c +++ b/src/cmAudioFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudioFile.h b/src/cmAudioFile.h index 7623723..4bb3dc5 100644 --- a/src/cmAudioFile.h +++ b/src/cmAudioFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc: "Read and write AIFF and WAV audio files." kw:[file audio] } // // This class supports reading uncompressed AIFF and WAV files and writing uncompressed AIFF files. diff --git a/src/cmAudioFileDev.c b/src/cmAudioFileDev.c index 34ca584..e890ebb 100644 --- a/src/cmAudioFileDev.c +++ b/src/cmAudioFileDev.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmAudioFileDev.h b/src/cmAudioFileDev.h index 137a528..0009b37 100644 --- a/src/cmAudioFileDev.h +++ b/src/cmAudioFileDev.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioFileDev_h #define cmAudioFileDev_h diff --git a/src/cmAudioFileMgr.c b/src/cmAudioFileMgr.c index 0d9f544..529d41e 100644 --- a/src/cmAudioFileMgr.c +++ b/src/cmAudioFileMgr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmAudioFileMgr.h b/src/cmAudioFileMgr.h index 9dde2b4..00cd44c 100644 --- a/src/cmAudioFileMgr.h +++ b/src/cmAudioFileMgr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioFileMgr_h #define cmAudioFileMgr_h diff --git a/src/cmAudioNrtDev.c b/src/cmAudioNrtDev.c index 1408df3..136ac08 100644 --- a/src/cmAudioNrtDev.c +++ b/src/cmAudioNrtDev.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmAudioNrtDev.h b/src/cmAudioNrtDev.h index cb3c553..22a014a 100644 --- a/src/cmAudioNrtDev.h +++ b/src/cmAudioNrtDev.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioNrtDev_h #define cmAudioNrtDev_h diff --git a/src/cmAudioPort.c b/src/cmAudioPort.c index 68e9a7e..59f5773 100644 --- a/src/cmAudioPort.c +++ b/src/cmAudioPort.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmAudioPort.h b/src/cmAudioPort.h index 4eedbd1..fb4e666 100644 --- a/src/cmAudioPort.h +++ b/src/cmAudioPort.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc: "Cross platform audio device interface." kw:[audio rt devices] } // // This interface provides data declarations for platform dependent diff --git a/src/cmAudioPortFile.c b/src/cmAudioPortFile.c index c497c93..e2eae43 100644 --- a/src/cmAudioPortFile.c +++ b/src/cmAudioPortFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmAudioPortFile.h b/src/cmAudioPortFile.h index 6548928..3c86d16 100644 --- a/src/cmAudioPortFile.h +++ b/src/cmAudioPortFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioPortFile_h #define cmAudioPortFile_h diff --git a/src/cmAudioSys.c b/src/cmAudioSys.c index 8fe484a..64583ba 100644 --- a/src/cmAudioSys.c +++ b/src/cmAudioSys.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmAudioSys.h b/src/cmAudioSys.h index 7fc5c8d..b8500d8 100644 --- a/src/cmAudioSys.h +++ b/src/cmAudioSys.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc: "This is the kernel of a real-time audio processing engine." kw:[audio rt] } // // The audio system is composed a collection of independent sub-systems. diff --git a/src/cmAudioSysMsg.h b/src/cmAudioSysMsg.h index 38c90b8..73c8318 100644 --- a/src/cmAudioSysMsg.h +++ b/src/cmAudioSysMsg.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioSysMsg_h #define cmAudioSysMsg_h diff --git a/src/cmComplexTypes.c b/src/cmComplexTypes.c index c8f5a11..0cd8875 100644 --- a/src/cmComplexTypes.c +++ b/src/cmComplexTypes.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmComplexTypes.h b/src/cmComplexTypes.h index c2e6742..b7c6b7e 100644 --- a/src/cmComplexTypes.h +++ b/src/cmComplexTypes.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmComplexTypes_h #define cmComplexTypes_h diff --git a/src/cmCsv.c b/src/cmCsv.c index 8ece1ce..586cbb9 100644 --- a/src/cmCsv.c +++ b/src/cmCsv.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmCsv.h b/src/cmCsv.h index b90933d..ced660d 100644 --- a/src/cmCsv.h +++ b/src/cmCsv.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmCsv_h #define cmCsv_h diff --git a/src/cmCtx.c b/src/cmCtx.c index acdfc7c..587c965 100644 --- a/src/cmCtx.c +++ b/src/cmCtx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmCtx.h b/src/cmCtx.h index 55e91a0..e1e9c7b 100644 --- a/src/cmCtx.h +++ b/src/cmCtx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Global application context record." kw[base] } // diff --git a/src/cmDList.c b/src/cmDList.c index 29b6a63..5819ec9 100644 --- a/src/cmDList.c +++ b/src/cmDList.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmDList.h b/src/cmDList.h index 2be3995..2cb3bca 100644 --- a/src/cmDList.h +++ b/src/cmDList.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDList_h #define cmDList_h diff --git a/src/cmDListTpl.h b/src/cmDListTpl.h index 0448d92..75ed2aa 100644 --- a/src/cmDListTpl.h +++ b/src/cmDListTpl.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Template 'include' code for using cmDList as a template." kw:[container] } diff --git a/src/cmData.c b/src/cmData.c index 3bf2967..6441a83 100644 --- a/src/cmData.c +++ b/src/cmData.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmData.h b/src/cmData.h index 6b01b9a..ff6c39b 100644 --- a/src/cmData.h +++ b/src/cmData.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmData_h #define cmData_h diff --git a/src/cmDevCfg.c b/src/cmDevCfg.c index 8528b8d..847b2a3 100644 --- a/src/cmDevCfg.c +++ b/src/cmDevCfg.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmDevCfg.h b/src/cmDevCfg.h index f9e2fb5..b2f05eb 100644 --- a/src/cmDevCfg.h +++ b/src/cmDevCfg.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDevCfg_h #define cmDevCfg_h diff --git a/src/cmErr.c b/src/cmErr.c index e833b2b..2369ebb 100644 --- a/src/cmErr.c +++ b/src/cmErr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmErr.h b/src/cmErr.h index b172005..7698dba 100644 --- a/src/cmErr.h +++ b/src/cmErr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Format error messages and track the last error generated." kw:[base]} // // This class is used to format error messages and track the last error generated. diff --git a/src/cmExec.c b/src/cmExec.c index c7b32f5..d1e5761 100644 --- a/src/cmExec.c +++ b/src/cmExec.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmExec.h b/src/cmExec.h index 5ecc234..e2032e8 100644 --- a/src/cmExec.h +++ b/src/cmExec.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmExec_h #define cmExec_h diff --git a/src/cmFeatFile.c b/src/cmFeatFile.c index 7e4b27e..2a900dc 100644 --- a/src/cmFeatFile.c +++ b/src/cmFeatFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmFeatFile.h b/src/cmFeatFile.h index 0647a11..2614fcc 100644 --- a/src/cmFeatFile.h +++ b/src/cmFeatFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:" Audio file acoustic feature analyzer and accompanying file reader." kw:[audio analysis file]} // // diff --git a/src/cmFile.c b/src/cmFile.c index 40550ce..34545ab 100644 --- a/src/cmFile.c +++ b/src/cmFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmFile.h b/src/cmFile.h index a49b8fe..9ce1a3e 100644 --- a/src/cmFile.h +++ b/src/cmFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmFile_h #define cmFile_h diff --git a/src/cmFileSys.c b/src/cmFileSys.c index eaa1f24..3b6a208 100644 --- a/src/cmFileSys.c +++ b/src/cmFileSys.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmFileSys.h b/src/cmFileSys.h index a067ae6..2cce253 100644 --- a/src/cmFileSys.h +++ b/src/cmFileSys.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"A collection of file system utility functions." kw:[system file]} // diff --git a/src/cmFloatTypes.h b/src/cmFloatTypes.h index 9ba574a..07d6344 100644 --- a/src/cmFloatTypes.h +++ b/src/cmFloatTypes.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmFloatTypes_h #define cmFloatTypes_h diff --git a/src/cmFrameFile.c b/src/cmFrameFile.c index fecb528..74da171 100644 --- a/src/cmFrameFile.c +++ b/src/cmFrameFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmFrameFile.h b/src/cmFrameFile.h index bcb137a..2a1c28f 100644 --- a/src/cmFrameFile.h +++ b/src/cmFrameFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmFrameFile_h #define cmFrameFile_h diff --git a/src/cmGlobal.c b/src/cmGlobal.c index 139597f..b06d4fd 100644 --- a/src/cmGlobal.c +++ b/src/cmGlobal.c @@ -1,2 +1,4 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. diff --git a/src/cmGlobal.h b/src/cmGlobal.h index 41f6c4d..37b12ac 100644 --- a/src/cmGlobal.h +++ b/src/cmGlobal.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGlobal_h diff --git a/src/cmGnuPlot.c b/src/cmGnuPlot.c index 3730692..78aa0aa 100644 --- a/src/cmGnuPlot.c +++ b/src/cmGnuPlot.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmGnuPlot.h b/src/cmGnuPlot.h index 7f74083..1ee8fba 100644 --- a/src/cmGnuPlot.h +++ b/src/cmGnuPlot.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGnuPlot_h #define cmGnuPlot_h diff --git a/src/cmGr.c b/src/cmGr.c index aaa6c07..7a975c4 100644 --- a/src/cmGr.c +++ b/src/cmGr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmGr.h b/src/cmGr.h index d25f6c6..0bec485 100644 --- a/src/cmGr.h +++ b/src/cmGr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGr_h #define cmGr_h diff --git a/src/cmGrDevCtx.c b/src/cmGrDevCtx.c index ab1ca31..90601ee 100644 --- a/src/cmGrDevCtx.c +++ b/src/cmGrDevCtx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmGrDevCtx.h b/src/cmGrDevCtx.h index dd1a8a1..91c06a5 100644 --- a/src/cmGrDevCtx.h +++ b/src/cmGrDevCtx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGrDevCtx_h #define cmGrDevCtx_h diff --git a/src/cmGrPage.c b/src/cmGrPage.c index b25c4a2..307b0f4 100644 --- a/src/cmGrPage.c +++ b/src/cmGrPage.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmGrPage.h b/src/cmGrPage.h index 034e5d8..fc0800f 100644 --- a/src/cmGrPage.h +++ b/src/cmGrPage.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGrPage_h #define cmGrPage_h diff --git a/src/cmGrPlot.c b/src/cmGrPlot.c index eef9ff9..221dad1 100644 --- a/src/cmGrPlot.c +++ b/src/cmGrPlot.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmGrPlot.h b/src/cmGrPlot.h index fbb1407..7e1c639 100644 --- a/src/cmGrPlot.h +++ b/src/cmGrPlot.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGrTimeLine_h #define cmGrTimeLine_h diff --git a/src/cmGrPlotAudio.c b/src/cmGrPlotAudio.c index 2866bd9..6bc1952 100644 --- a/src/cmGrPlotAudio.c +++ b/src/cmGrPlotAudio.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmGrPlotAudio.h b/src/cmGrPlotAudio.h index 761c31e..3b65e53 100644 --- a/src/cmGrPlotAudio.h +++ b/src/cmGrPlotAudio.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmGrPlotAudio_h #define cmGrPlotAudio_h diff --git a/src/cmHashTbl.c b/src/cmHashTbl.c index c4f628a..634023c 100644 --- a/src/cmHashTbl.c +++ b/src/cmHashTbl.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmHashTbl.h b/src/cmHashTbl.h index 3737756..a40fa16 100644 --- a/src/cmHashTbl.h +++ b/src/cmHashTbl.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmHashTbl_h #define cmHashTbl_h diff --git a/src/cmJson.c b/src/cmJson.c index 701bbdd..09e9ba7 100644 --- a/src/cmJson.c +++ b/src/cmJson.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmJson.h b/src/cmJson.h index 2ddc033..fa74416 100644 --- a/src/cmJson.h +++ b/src/cmJson.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmJson_h #define cmJson_h diff --git a/src/cmKeyboard.c b/src/cmKeyboard.c index b065ec3..e62b6b3 100644 --- a/src/cmKeyboard.c +++ b/src/cmKeyboard.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmKeyboard.h" diff --git a/src/cmKeyboard.h b/src/cmKeyboard.h index 1ca3ade..20bc15d 100644 --- a/src/cmKeyboard.h +++ b/src/cmKeyboard.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmKeyboard_h #define cmKeyboard_h diff --git a/src/cmLex.c b/src/cmLex.c index f9dd88b..72fc480 100644 --- a/src/cmLex.c +++ b/src/cmLex.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmLex.h b/src/cmLex.h index fde88c4..df91643 100644 --- a/src/cmLex.h +++ b/src/cmLex.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmLex_h #define cmLex_h diff --git a/src/cmLib.c b/src/cmLib.c index 278191f..f86520e 100644 --- a/src/cmLib.c +++ b/src/cmLib.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmLib.h b/src/cmLib.h index 14895d8..0b3a460 100644 --- a/src/cmLib.h +++ b/src/cmLib.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmLib_h #define cmLib_h diff --git a/src/cmLinkedHeap.c b/src/cmLinkedHeap.c index 3462db3..3de3cc2 100644 --- a/src/cmLinkedHeap.c +++ b/src/cmLinkedHeap.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmLinkedHeap.h b/src/cmLinkedHeap.h index 59e0074..4ef4982 100644 --- a/src/cmLinkedHeap.h +++ b/src/cmLinkedHeap.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmLinkedHeap_h #define cmLinkedHeap_h diff --git a/src/cmMain.c b/src/cmMain.c index 1a5f81f..9fc96ae 100644 --- a/src/cmMain.c +++ b/src/cmMain.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Template 'main.c' for 'libcm' based program" kw:[demo]} #include "cmGlobal.h" diff --git a/src/cmMallocDebug.c b/src/cmMallocDebug.c index df69020..8e27808 100644 --- a/src/cmMallocDebug.c +++ b/src/cmMallocDebug.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmMallocDebug.h b/src/cmMallocDebug.h index 3ce1723..e65d8d1 100644 --- a/src/cmMallocDebug.h +++ b/src/cmMallocDebug.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMallocDebug_h #define cmMallocDebug_h diff --git a/src/cmMath.c b/src/cmMath.c index 72ce7fd..d964881 100644 --- a/src/cmMath.c +++ b/src/cmMath.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmMath.h b/src/cmMath.h index e50aeac..333cd07 100644 --- a/src/cmMath.h +++ b/src/cmMath.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMath_h #define cmMath_h diff --git a/src/cmMem.c b/src/cmMem.c index 6c9e35e..0155bdd 100644 --- a/src/cmMem.c +++ b/src/cmMem.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmMem.h b/src/cmMem.h index 3ad1055..3fcf6ee 100644 --- a/src/cmMem.h +++ b/src/cmMem.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc: "Implements a memory allocation manager interface." kw:[ base ]} // // diff --git a/src/cmMidi.c b/src/cmMidi.c index 830fb38..67b6ac5 100644 --- a/src/cmMidi.c +++ b/src/cmMidi.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmTime.h" diff --git a/src/cmMidi.h b/src/cmMidi.h index b9ae113..13b34e2 100644 --- a/src/cmMidi.h +++ b/src/cmMidi.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMidi_h #define cmMidi_h diff --git a/src/cmMidiFile.c b/src/cmMidiFile.c index a47f413..6167289 100644 --- a/src/cmMidiFile.c +++ b/src/cmMidiFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmMidiFile.h b/src/cmMidiFile.h index b5428e2..c168766 100644 --- a/src/cmMidiFile.h +++ b/src/cmMidiFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMidiFile_h #define cmMidiFile_h diff --git a/src/cmMidiFilePlay.c b/src/cmMidiFilePlay.c index bf20a01..e644e60 100644 --- a/src/cmMidiFilePlay.c +++ b/src/cmMidiFilePlay.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include // gettimeofday() #include "cmPrefix.h" #include "cmGlobal.h" diff --git a/src/cmMidiFilePlay.h b/src/cmMidiFilePlay.h index ace61d7..60dfb2e 100644 --- a/src/cmMidiFilePlay.h +++ b/src/cmMidiFilePlay.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef midiFilePlay_h #define midiFilePlay_h diff --git a/src/cmMidiPort.c b/src/cmMidiPort.c index 7566390..410e86f 100644 --- a/src/cmMidiPort.c +++ b/src/cmMidiPort.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmMidiPort.h b/src/cmMidiPort.h index abb44b1..f6b311b 100644 --- a/src/cmMidiPort.h +++ b/src/cmMidiPort.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMidiPort_h #define cmMidiPort_h diff --git a/src/cmMsgProtocol.c b/src/cmMsgProtocol.c index fdd5732..a9cbac4 100644 --- a/src/cmMsgProtocol.c +++ b/src/cmMsgProtocol.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmMsgProtocol.h b/src/cmMsgProtocol.h index e96e96a..2c840da 100644 --- a/src/cmMsgProtocol.h +++ b/src/cmMsgProtocol.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmMsgProtocol_h #define cmMsgProtocol_h diff --git a/src/cmPP_NARG.h b/src/cmPP_NARG.h index 498d0e2..73214f5 100644 --- a/src/cmPP_NARG.h +++ b/src/cmPP_NARG.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmPP_NARG_H #define cmPP_NARG_H diff --git a/src/cmPgmOpts.c b/src/cmPgmOpts.c index be0de7c..9443ecb 100644 --- a/src/cmPgmOpts.c +++ b/src/cmPgmOpts.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmPgmOpts.h b/src/cmPgmOpts.h index 46c533e..7199c01 100644 --- a/src/cmPgmOpts.h +++ b/src/cmPgmOpts.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmPgmOpts_h #define cmPgmOpts_h diff --git a/src/cmPrefix.h b/src/cmPrefix.h index 4a88c53..4cc1db0 100644 --- a/src/cmPrefix.h +++ b/src/cmPrefix.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmPrefix_h #define cmPrefix_h diff --git a/src/cmPrefs.c b/src/cmPrefs.c index a573d47..701f985 100644 --- a/src/cmPrefs.c +++ b/src/cmPrefs.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmPrefs.h b/src/cmPrefs.h index 80f90ec..3bb4f16 100644 --- a/src/cmPrefs.h +++ b/src/cmPrefs.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmPrefs_h #define cmPrefs_h diff --git a/src/cmProc.c b/src/cmProc.c index 8531a04..025611e 100644 --- a/src/cmProc.c +++ b/src/cmProc.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProc.h b/src/cmProc.h index 2f2242b..b4405de 100644 --- a/src/cmProc.h +++ b/src/cmProc.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProc_h #define cmProc_h diff --git a/src/cmProc2.c b/src/cmProc2.c index 1fd2545..b8abe79 100644 --- a/src/cmProc2.c +++ b/src/cmProc2.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProc2.h b/src/cmProc2.h index 2b9ec49..d1a5be7 100644 --- a/src/cmProc2.h +++ b/src/cmProc2.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProc2_h #define cmProc2_h diff --git a/src/cmProc3.c b/src/cmProc3.c index 7aa56a9..a52d06b 100644 --- a/src/cmProc3.c +++ b/src/cmProc3.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProc3.h b/src/cmProc3.h index 6e354d7..e0acfd7 100644 --- a/src/cmProc3.h +++ b/src/cmProc3.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProc3_h #define cmProc3_h diff --git a/src/cmProc4.c b/src/cmProc4.c index 89d312b..19ce23d 100644 --- a/src/cmProc4.c +++ b/src/cmProc4.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProc4.h b/src/cmProc4.h index b2d3fcb..06ed48b 100644 --- a/src/cmProc4.h +++ b/src/cmProc4.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProc4_h #define cmProc4_h diff --git a/src/cmProc5.c b/src/cmProc5.c index c03c679..985e9c1 100644 --- a/src/cmProc5.c +++ b/src/cmProc5.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProc5.h b/src/cmProc5.h index fea9cf0..70b1ee6 100644 --- a/src/cmProc5.h +++ b/src/cmProc5.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProc5_h #define cmProc5_h diff --git a/src/cmProcObj.c b/src/cmProcObj.c index 949a008..44dbfbe 100644 --- a/src/cmProcObj.c +++ b/src/cmProcObj.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmProcObj.h b/src/cmProcObj.h index 5baf876..18ecdc0 100644 --- a/src/cmProcObj.h +++ b/src/cmProcObj.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProcObj_h #define cmProcObj_h diff --git a/src/cmProcTest.c b/src/cmProcTest.c index 890dd26..c1f7ed6 100644 --- a/src/cmProcTest.c +++ b/src/cmProcTest.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmProcTest.h b/src/cmProcTest.h index 23d7d0b..2ac07b0 100644 --- a/src/cmProcTest.h +++ b/src/cmProcTest.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProcTest_h #define cmProcTest_h diff --git a/src/cmRbm.c b/src/cmRbm.c index 5a1f2b5..e2d15f4 100644 --- a/src/cmRbm.c +++ b/src/cmRbm.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmRbm.h b/src/cmRbm.h index 59deebd..dbf4a1e 100644 --- a/src/cmRbm.h +++ b/src/cmRbm.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmRbm_h #define cmRbm_h diff --git a/src/cmRpt.c b/src/cmRpt.c index 716c599..8a07bdf 100644 --- a/src/cmRpt.c +++ b/src/cmRpt.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmRpt.h b/src/cmRpt.h index f2e3c33..0cb2574 100644 --- a/src/cmRpt.h +++ b/src/cmRpt.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmRpt_h #define cmRpt_h diff --git a/src/cmRptFile.c b/src/cmRptFile.c index 1bfe22b..7ad475c 100644 --- a/src/cmRptFile.c +++ b/src/cmRptFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmRptFile.h b/src/cmRptFile.h index d8d9109..3fb426a 100644 --- a/src/cmRptFile.h +++ b/src/cmRptFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmRptFile_h #define cmRptFile_h diff --git a/src/cmRtNet.c b/src/cmRtNet.c index 9d3172d..54831fc 100644 --- a/src/cmRtNet.c +++ b/src/cmRtNet.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmRtNet.h b/src/cmRtNet.h index 964ce31..450aca8 100644 --- a/src/cmRtNet.h +++ b/src/cmRtNet.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmRtNet_h #define cmRtNet_h diff --git a/src/cmRtSys.c b/src/cmRtSys.c index a42527b..fef56e4 100644 --- a/src/cmRtSys.c +++ b/src/cmRtSys.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmRtSys.h b/src/cmRtSys.h index 3f01342..9385c52 100644 --- a/src/cmRtSys.h +++ b/src/cmRtSys.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Improved real-time audio processing engine." kw:[rtsys] } // // The audio system is composed a collection of independent sub-systems. diff --git a/src/cmRtSysMsg.h b/src/cmRtSysMsg.h index 1c52698..b28c6bd 100644 --- a/src/cmRtSysMsg.h +++ b/src/cmRtSysMsg.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmRtSysMsg_h #define cmRtSysMsg_h diff --git a/src/cmSerialPort.c b/src/cmSerialPort.c index 8f5093d..336ed51 100644 --- a/src/cmSerialPort.c +++ b/src/cmSerialPort.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmSerialPort.h b/src/cmSerialPort.h index a44c614..d3ac33e 100644 --- a/src/cmSerialPort.h +++ b/src/cmSerialPort.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSerialPort_h #define cmSerialPort_h diff --git a/src/cmSerialize.c b/src/cmSerialize.c index 7f6728a..7a0f2c6 100644 --- a/src/cmSerialize.c +++ b/src/cmSerialize.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmSerialize.h b/src/cmSerialize.h index 4780632..cb9058f 100644 --- a/src/cmSerialize.h +++ b/src/cmSerialize.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSerialize_h #define cmSerialize_h diff --git a/src/cmStack.c b/src/cmStack.c index 7b3b3c5..7846886 100644 --- a/src/cmStack.c +++ b/src/cmStack.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmStack.h b/src/cmStack.h index 9b6691b..ab37c47 100644 --- a/src/cmStack.h +++ b/src/cmStack.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmStack_h #define cmStack_h diff --git a/src/cmStrStream.c b/src/cmStrStream.c index 8508c52..99895bc 100644 --- a/src/cmStrStream.c +++ b/src/cmStrStream.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmStrStream.h b/src/cmStrStream.h index 81b872f..beae0f7 100644 --- a/src/cmStrStream.h +++ b/src/cmStrStream.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmStrStream_h #define cmStrStream_h diff --git a/src/cmSvgWriter.c b/src/cmSvgWriter.c index 2433f1a..2ff1dbe 100644 --- a/src/cmSvgWriter.c +++ b/src/cmSvgWriter.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmSvgWriter.h b/src/cmSvgWriter.h index 0e9db43..6f38231 100644 --- a/src/cmSvgWriter.h +++ b/src/cmSvgWriter.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSvgWriter_h #define cmSvgWriter_h diff --git a/src/cmSymTbl.c b/src/cmSymTbl.c index cf255ef..78faf46 100644 --- a/src/cmSymTbl.c +++ b/src/cmSymTbl.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmSymTbl.h b/src/cmSymTbl.h index 3482ed5..df11083 100644 --- a/src/cmSymTbl.h +++ b/src/cmSymTbl.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSymTbl_h #define cmSymTbl_h diff --git a/src/cmSyncRecd.c b/src/cmSyncRecd.c index 774a369..d40fbc4 100644 --- a/src/cmSyncRecd.c +++ b/src/cmSyncRecd.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmSyncRecd.h b/src/cmSyncRecd.h index f4d18dd..3a5d2d1 100644 --- a/src/cmSyncRecd.h +++ b/src/cmSyncRecd.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSyncRecd_h #define cmSyncRecd_h diff --git a/src/cmTagFile.c b/src/cmTagFile.c index 035433b..bf3414e 100644 --- a/src/cmTagFile.c +++ b/src/cmTagFile.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmTagFile.h b/src/cmTagFile.h index 8e96128..d58a4f7 100644 --- a/src/cmTagFile.h +++ b/src/cmTagFile.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmTagFile_h #define cmTagFile_h diff --git a/src/cmTaskMgr.c b/src/cmTaskMgr.c index 109bd63..e982d24 100644 --- a/src/cmTaskMgr.c +++ b/src/cmTaskMgr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmTaskMgr.h b/src/cmTaskMgr.h index 4b80a32..146d7a2 100644 --- a/src/cmTaskMgr.h +++ b/src/cmTaskMgr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmTaskMgr_h #define cmTaskMgr_h diff --git a/src/cmText.c b/src/cmText.c index d9e9106..d04febb 100644 --- a/src/cmText.c +++ b/src/cmText.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmText.h b/src/cmText.h index aaa52cd..9b397b6 100644 --- a/src/cmText.h +++ b/src/cmText.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmText_h #define cmText_h diff --git a/src/cmTextTemplate.c b/src/cmTextTemplate.c index c6c96a8..28a994b 100644 --- a/src/cmTextTemplate.c +++ b/src/cmTextTemplate.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmTextTemplate.h b/src/cmTextTemplate.h index 7a7dbd4..aa190df 100644 --- a/src/cmTextTemplate.h +++ b/src/cmTextTemplate.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmTextTemplate_h #define cmTextTemplate_h diff --git a/src/cmThread.c b/src/cmThread.c index 87f10b2..811f033 100644 --- a/src/cmThread.c +++ b/src/cmThread.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" diff --git a/src/cmThread.h b/src/cmThread.h index 5970d0c..8c01030 100644 --- a/src/cmThread.h +++ b/src/cmThread.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmThread_h #define cmThread_h diff --git a/src/cmTime.c b/src/cmTime.c index 042e30f..9f05b68 100644 --- a/src/cmTime.c +++ b/src/cmTime.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmTime.h" diff --git a/src/cmTime.h b/src/cmTime.h index d161db2..1534aff 100644 --- a/src/cmTime.h +++ b/src/cmTime.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Time cand clock related functions." kw: [ time system ] } // diff --git a/src/cmUdpNet.c b/src/cmUdpNet.c index 999821a..69f8e27 100644 --- a/src/cmUdpNet.c +++ b/src/cmUdpNet.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmUdpNet.h b/src/cmUdpNet.h index efb2e23..772803f 100644 --- a/src/cmUdpNet.h +++ b/src/cmUdpNet.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmUdpNet_h #define cmUdpNet_h diff --git a/src/cmUdpPort.c b/src/cmUdpPort.c index c65e3f8..458e764 100644 --- a/src/cmUdpPort.c +++ b/src/cmUdpPort.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/cmUdpPort.h b/src/cmUdpPort.h index 418774f..fac72b9 100644 --- a/src/cmUdpPort.h +++ b/src/cmUdpPort.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmUdpPort_h #define cmUdpPort_h diff --git a/src/cmUi.c b/src/cmUi.c index fc53268..f771031 100644 --- a/src/cmUi.c +++ b/src/cmUi.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmUi.h b/src/cmUi.h index 60d2f67..418956a 100644 --- a/src/cmUi.h +++ b/src/cmUi.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmUi_h #define cmUi_h diff --git a/src/cmUiDrvr.c b/src/cmUiDrvr.c index 146cece..8c6fc6e 100644 --- a/src/cmUiDrvr.c +++ b/src/cmUiDrvr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRtSysMsg.h" #include "cmUiDrvr.h" diff --git a/src/cmUiDrvr.h b/src/cmUiDrvr.h index 5196e6f..0199a34 100644 --- a/src/cmUiDrvr.h +++ b/src/cmUiDrvr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmUiDrvr_h #define cmUiDrvr_h diff --git a/src/cmUiRtSysMstr.c b/src/cmUiRtSysMstr.c index 6ad22aa..83a290e 100644 --- a/src/cmUiRtSysMstr.c +++ b/src/cmUiRtSysMstr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/cmUiRtSysMstr.h b/src/cmUiRtSysMstr.h index 06fda30..ff76e0a 100644 --- a/src/cmUiRtSysMstr.h +++ b/src/cmUiRtSysMstr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmUiRtSysMstr_h #define cmUiRtSysMstr_h diff --git a/src/cmVectOpsDocOut.h b/src/cmVectOpsDocOut.h index 8f9c189..71d05b2 100644 --- a/src/cmVectOpsDocOut.h +++ b/src/cmVectOpsDocOut.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Math vector operations." kw:[vop math] } //) //( { label:misc desc:"Miscellaneous vector operations." kw:[vop] } diff --git a/src/cmVirtNet.c b/src/cmVirtNet.c index 4ce9334..fc36bee 100644 --- a/src/cmVirtNet.c +++ b/src/cmVirtNet.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmRpt.h" #include "cmErr.h" diff --git a/src/cmVirtNet.h b/src/cmVirtNet.h index 7b22dcc..9ff4331 100644 --- a/src/cmVirtNet.h +++ b/src/cmVirtNet.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmVirtNet_h #define cmVirtNet_h diff --git a/src/cmXml.c b/src/cmXml.c index 05399ee..8b70bda 100644 --- a/src/cmXml.c +++ b/src/cmXml.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/cmXml.h b/src/cmXml.h index 08e7836..9a89897 100644 --- a/src/cmXml.h +++ b/src/cmXml.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmXml_h #define cmXml_h diff --git a/src/dsp/cmDspBuiltIn.c b/src/dsp/cmDspBuiltIn.c index eea6070..11788f1 100644 --- a/src/dsp/cmDspBuiltIn.c +++ b/src/dsp/cmDspBuiltIn.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Built-in 'snap' processor units." kw:[snap]} #include "cmPrefix.h" diff --git a/src/dsp/cmDspBuiltIn.h b/src/dsp/cmDspBuiltIn.h index dabb6c0..adc3c9c 100644 --- a/src/dsp/cmDspBuiltIn.h +++ b/src/dsp/cmDspBuiltIn.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspBuiltIn_h #define cmDspBuiltIn_h diff --git a/src/dsp/cmDspClass.c b/src/dsp/cmDspClass.c index afeaa7b..8a97e9e 100644 --- a/src/dsp/cmDspClass.c +++ b/src/dsp/cmDspClass.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspClass.h b/src/dsp/cmDspClass.h index 8d2da2e..de99730 100644 --- a/src/dsp/cmDspClass.h +++ b/src/dsp/cmDspClass.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspClass_h #define cmDspClass_h diff --git a/src/dsp/cmDspCtx.h b/src/dsp/cmDspCtx.h index 5992cfa..afb28fa 100644 --- a/src/dsp/cmDspCtx.h +++ b/src/dsp/cmDspCtx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspCtx_h #define cmDspCtx_h diff --git a/src/dsp/cmDspFx.c b/src/dsp/cmDspFx.c index bbb1c68..f6ea6ed 100644 --- a/src/dsp/cmDspFx.c +++ b/src/dsp/cmDspFx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"'snap' audio effects processor units." kw:[snap]} #include "cmPrefix.h" diff --git a/src/dsp/cmDspFx.h b/src/dsp/cmDspFx.h index 08edbbf..916b930 100644 --- a/src/dsp/cmDspFx.h +++ b/src/dsp/cmDspFx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspFx_h #define cmDspFx_h diff --git a/src/dsp/cmDspKr.c b/src/dsp/cmDspKr.c index 187a233..7832e4c 100644 --- a/src/dsp/cmDspKr.c +++ b/src/dsp/cmDspKr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspKr.h b/src/dsp/cmDspKr.h index 9a70cb6..476fa83 100644 --- a/src/dsp/cmDspKr.h +++ b/src/dsp/cmDspKr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspKr_h #define cmDspKr_h diff --git a/src/dsp/cmDspMod.c b/src/dsp/cmDspMod.c index 0243f17..4f9554b 100644 --- a/src/dsp/cmDspMod.c +++ b/src/dsp/cmDspMod.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. typedef struct { unsigned modSymId; diff --git a/src/dsp/cmDspNet.c b/src/dsp/cmDspNet.c index 7844a64..51e326f 100644 --- a/src/dsp/cmDspNet.c +++ b/src/dsp/cmDspNet.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspNet.h b/src/dsp/cmDspNet.h index f38b7aa..d3106d3 100644 --- a/src/dsp/cmDspNet.h +++ b/src/dsp/cmDspNet.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspNet_h #define cmDspNet_h diff --git a/src/dsp/cmDspPgm.c b/src/dsp/cmDspPgm.c index fb347bb..c34d6f2 100644 --- a/src/dsp/cmDspPgm.c +++ b/src/dsp/cmDspPgm.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"'snap' programs." kw:[snap] } #include "cmPrefix.h" #include "cmGlobal.h" diff --git a/src/dsp/cmDspPgm.h b/src/dsp/cmDspPgm.h index 5e0ed70..ed7cac1 100644 --- a/src/dsp/cmDspPgm.h +++ b/src/dsp/cmDspPgm.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgm_h #define cmDspPgm_h diff --git a/src/dsp/cmDspPgmKr.c b/src/dsp/cmDspPgmKr.c index 141a319..d67644c 100644 --- a/src/dsp/cmDspPgmKr.c +++ b/src/dsp/cmDspPgmKr.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"'snap' Performance analysis Time Line program." kw:[snap]} #include "cmPrefix.h" diff --git a/src/dsp/cmDspPgmKr.h b/src/dsp/cmDspPgmKr.h index f19643b..8cc33b2 100644 --- a/src/dsp/cmDspPgmKr.h +++ b/src/dsp/cmDspPgmKr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgmKr_h #define cmDspPgmKr_h diff --git a/src/dsp/cmDspPgmKrChain.c b/src/dsp/cmDspPgmKrChain.c index e5661ba..cc906b6 100644 --- a/src/dsp/cmDspPgmKrChain.c +++ b/src/dsp/cmDspPgmKrChain.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspPgmKrChain.h b/src/dsp/cmDspPgmKrChain.h index 36257bf..c9943c0 100644 --- a/src/dsp/cmDspPgmKrChain.h +++ b/src/dsp/cmDspPgmKrChain.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgmKrChain_h #define cmDspPgmKrChain_h diff --git a/src/dsp/cmDspPgmKrChain2.c b/src/dsp/cmDspPgmKrChain2.c index 051b509..d4d9142 100644 --- a/src/dsp/cmDspPgmKrChain2.c +++ b/src/dsp/cmDspPgmKrChain2.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspPgmKrTimeLineLite.c b/src/dsp/cmDspPgmKrTimeLineLite.c index 262b87c..f34991f 100644 --- a/src/dsp/cmDspPgmKrTimeLineLite.c +++ b/src/dsp/cmDspPgmKrTimeLineLite.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"'snap' Performance analysis Simplified Time Line program." kw:[snap]} #include "cmPrefix.h" diff --git a/src/dsp/cmDspPgmKrTimeLineLiteAf.c b/src/dsp/cmDspPgmKrTimeLineLiteAf.c index dc07094..170f8f1 100644 --- a/src/dsp/cmDspPgmKrTimeLineLiteAf.c +++ b/src/dsp/cmDspPgmKrTimeLineLiteAf.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"'snap' Performance analysis Simplified Time Line program." kw:[snap]} #include "cmPrefix.h" diff --git a/src/dsp/cmDspPgmKrTksb.c b/src/dsp/cmDspPgmKrTksb.c index 184e7a0..82fd845 100644 --- a/src/dsp/cmDspPgmKrTksb.c +++ b/src/dsp/cmDspPgmKrTksb.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspPgmPP.c b/src/dsp/cmDspPgmPP.c index 6ce3886..2c6c340 100644 --- a/src/dsp/cmDspPgmPP.c +++ b/src/dsp/cmDspPgmPP.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspPgmPP.h b/src/dsp/cmDspPgmPP.h index 9e015eb..7b4a737 100644 --- a/src/dsp/cmDspPgmPP.h +++ b/src/dsp/cmDspPgmPP.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgmPP_h #define cmDspPgmPP_h diff --git a/src/dsp/cmDspPgmPPMain.c b/src/dsp/cmDspPgmPPMain.c index c996ae7..a32265b 100644 --- a/src/dsp/cmDspPgmPPMain.c +++ b/src/dsp/cmDspPgmPPMain.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspPgmPPMain.h b/src/dsp/cmDspPgmPPMain.h index 87e33e7..631913a 100644 --- a/src/dsp/cmDspPgmPPMain.h +++ b/src/dsp/cmDspPgmPPMain.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPgmPPMain_h #define cmDspPgmPPMain_h diff --git a/src/dsp/cmDspPreset.c b/src/dsp/cmDspPreset.c index 83c6cc4..f4f8173 100644 --- a/src/dsp/cmDspPreset.c +++ b/src/dsp/cmDspPreset.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmGlobal.h" #include "cmFloatTypes.h" #include "cmRpt.h" diff --git a/src/dsp/cmDspPreset.h b/src/dsp/cmDspPreset.h index cfecd5f..7aa0132 100644 --- a/src/dsp/cmDspPreset.h +++ b/src/dsp/cmDspPreset.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspPresetMgr_h #define cmDspPresetMgr_h diff --git a/src/dsp/cmDspStore.c b/src/dsp/cmDspStore.c index 2019cdd..0b802e6 100644 --- a/src/dsp/cmDspStore.c +++ b/src/dsp/cmDspStore.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspStore.h b/src/dsp/cmDspStore.h index 89fb876..5cfe29c 100644 --- a/src/dsp/cmDspStore.h +++ b/src/dsp/cmDspStore.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspStore_h #define cmDspStore_h diff --git a/src/dsp/cmDspSys.c b/src/dsp/cmDspSys.c index 1473fd5..59b0861 100644 --- a/src/dsp/cmDspSys.c +++ b/src/dsp/cmDspSys.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspSys.h b/src/dsp/cmDspSys.h index 5d78501..408dd36 100644 --- a/src/dsp/cmDspSys.h +++ b/src/dsp/cmDspSys.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspSys_h #define cmDspSys_h diff --git a/src/dsp/cmDspUi.c b/src/dsp/cmDspUi.c index 4ae728f..4c9c282 100644 --- a/src/dsp/cmDspUi.c +++ b/src/dsp/cmDspUi.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspUi.h b/src/dsp/cmDspUi.h index 8caff49..4960a0c 100644 --- a/src/dsp/cmDspUi.h +++ b/src/dsp/cmDspUi.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. // This file contains definitions that are common to both the host UI // and the DSP system. diff --git a/src/dsp/cmDspValue.c b/src/dsp/cmDspValue.c index 8a97b32..5f47a40 100644 --- a/src/dsp/cmDspValue.c +++ b/src/dsp/cmDspValue.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/dsp/cmDspValue.h b/src/dsp/cmDspValue.h index 4181339..c89baf9 100644 --- a/src/dsp/cmDspValue.h +++ b/src/dsp/cmDspValue.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmDspValue_h #define cmDspValue_h diff --git a/src/linux/cmAudioPortAlsa.c b/src/linux/cmAudioPortAlsa.c index 3a6606c..1667c4b 100644 --- a/src/linux/cmAudioPortAlsa.c +++ b/src/linux/cmAudioPortAlsa.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" diff --git a/src/linux/cmAudioPortAlsa.h b/src/linux/cmAudioPortAlsa.h index 4ebddac..ed180ef 100644 --- a/src/linux/cmAudioPortAlsa.h +++ b/src/linux/cmAudioPortAlsa.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioPortAlsa_h #define cmAudioPortAlsa_h diff --git a/src/linux/cmFileSysLinux.c b/src/linux/cmFileSysLinux.c index cfad588..cf53d15 100644 --- a/src/linux/cmFileSysLinux.c +++ b/src/linux/cmFileSysLinux.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/linux/cmFileSysLinux.h b/src/linux/cmFileSysLinux.h index 8cde5c5..bc0dd55 100644 --- a/src/linux/cmFileSysLinux.h +++ b/src/linux/cmFileSysLinux.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmFileSysLinux_h #define cmFileSysLinux_h diff --git a/src/linux/cmMidiAlsa.c b/src/linux/cmMidiAlsa.c index 0dd5d1c..b2c41c1 100644 --- a/src/linux/cmMidiAlsa.c +++ b/src/linux/cmMidiAlsa.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" diff --git a/src/osx/cmAudioPortOsx.c b/src/osx/cmAudioPortOsx.c index 95cdf1e..72f27fd 100644 --- a/src/osx/cmAudioPortOsx.c +++ b/src/osx/cmAudioPortOsx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. // // http://developer.apple.com/library/mac/#documentation/MusicAudio/Reference/CACoreAudioReference // diff --git a/src/osx/cmAudioPortOsx.h b/src/osx/cmAudioPortOsx.h index f87ba35..11e4b84 100644 --- a/src/osx/cmAudioPortOsx.h +++ b/src/osx/cmAudioPortOsx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmAudioPortOsx_h #define cmAudioPortOsx_h diff --git a/src/osx/cmFileSysOsx.c b/src/osx/cmFileSysOsx.c index bc80b1d..38f68e4 100644 --- a/src/osx/cmFileSysOsx.c +++ b/src/osx/cmFileSysOsx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/osx/cmFileSysOsx.h b/src/osx/cmFileSysOsx.h index 390b187..04bc6e2 100644 --- a/src/osx/cmFileSysOsx.h +++ b/src/osx/cmFileSysOsx.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmFileSysOsx_h #define cmFileSysOsx_h diff --git a/src/osx/cmMidiOsx.c b/src/osx/cmMidiOsx.c index 1b7e5d5..ada90af 100644 --- a/src/osx/cmMidiOsx.c +++ b/src/osx/cmMidiOsx.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include #include #include diff --git a/src/sa/cmSaProc.c b/src/sa/cmSaProc.c index 3899819..f6ae929 100644 --- a/src/sa/cmSaProc.c +++ b/src/sa/cmSaProc.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/sa/cmSaProc.h b/src/sa/cmSaProc.h index 8ae9187..3c5ceae 100644 --- a/src/sa/cmSaProc.h +++ b/src/sa/cmSaProc.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmSaProc_h #define cmSaProc_h diff --git a/src/vop/cmProcTemplate.c b/src/vop/cmProcTemplate.c index 25e9b5b..b28d008 100644 --- a/src/vop/cmProcTemplate.c +++ b/src/vop/cmProcTemplate.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmRpt.h" diff --git a/src/vop/cmProcTemplate.h b/src/vop/cmProcTemplate.h index 8b10372..80819a7 100644 --- a/src/vop/cmProcTemplate.h +++ b/src/vop/cmProcTemplate.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmProcTemplate_h #define cmProcTemplate_h diff --git a/src/vop/cmProcTemplateCode.h b/src/vop/cmProcTemplateCode.h index 5a3d633..62bad5d 100644 --- a/src/vop/cmProcTemplateCode.h +++ b/src/vop/cmProcTemplateCode.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifdef cmProcTemplateCode_h //----------------------------------------------------------------------------------------------------------- diff --git a/src/vop/cmProcTemplateHdr.h b/src/vop/cmProcTemplateHdr.h index 95bb29b..553218c 100644 --- a/src/vop/cmProcTemplateHdr.h +++ b/src/vop/cmProcTemplateHdr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. /* diff --git a/src/vop/cmProcTemplateMain.h b/src/vop/cmProcTemplateMain.h index e62132b..f10b08b 100644 --- a/src/vop/cmProcTemplateMain.h +++ b/src/vop/cmProcTemplateMain.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. // SS diff --git a/src/vop/cmProcTemplateUndef.h b/src/vop/cmProcTemplateUndef.h index 2448705..21a32ce 100644 --- a/src/vop/cmProcTemplateUndef.h +++ b/src/vop/cmProcTemplateUndef.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifdef T0 diff --git a/src/vop/cmVectOps.c b/src/vop/cmVectOps.c index 239efc4..7e9a180 100644 --- a/src/vop/cmVectOps.c +++ b/src/vop/cmVectOps.c @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #include "cmPrefix.h" #include "cmGlobal.h" #include "cmFloatTypes.h" diff --git a/src/vop/cmVectOps.h b/src/vop/cmVectOps.h index 27efe53..3773d9b 100644 --- a/src/vop/cmVectOps.h +++ b/src/vop/cmVectOps.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifndef cmVectOps_h #define cmVectOps_h diff --git a/src/vop/cmVectOpsDoc.h b/src/vop/cmVectOpsDoc.h index 6e4b109..96b7737 100644 --- a/src/vop/cmVectOpsDoc.h +++ b/src/vop/cmVectOpsDoc.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. // This file is used to generate the documentation // source file for cmVectOpsTemplateHdr.h and diff --git a/src/vop/cmVectOpsRICode.h b/src/vop/cmVectOpsRICode.h index 1bf7b55..f45e4fb 100644 --- a/src/vop/cmVectOpsRICode.h +++ b/src/vop/cmVectOpsRICode.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifdef cmVectOpsRICode_h VECT_OP_TYPE* VECT_OP_FUNC(Col)( VECT_OP_TYPE* m, unsigned ci, unsigned rn, unsigned cn ) diff --git a/src/vop/cmVectOpsRIHdr.h b/src/vop/cmVectOpsRIHdr.h index 11c6f11..664710f 100644 --- a/src/vop/cmVectOpsRIHdr.h +++ b/src/vop/cmVectOpsRIHdr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { label:"Matrix ops" desc:"Common 2D matrix operations and accessors." kw:[vop] } diff --git a/src/vop/cmVectOpsTemplateCode.h b/src/vop/cmVectOpsTemplateCode.h index 9a7247e..e9e1b87 100644 --- a/src/vop/cmVectOpsTemplateCode.h +++ b/src/vop/cmVectOpsTemplateCode.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifdef cmVectOpsTemplateCode_h VECT_OP_TYPE* VECT_OP_FUNC(CumSum)(VECT_OP_TYPE* dbp, unsigned dn, const VECT_OP_TYPE* sbp) diff --git a/src/vop/cmVectOpsTemplateHdr.h b/src/vop/cmVectOpsTemplateHdr.h index cb5da55..a7abe32 100644 --- a/src/vop/cmVectOpsTemplateHdr.h +++ b/src/vop/cmVectOpsTemplateHdr.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { label:misc desc:"Miscellaneous vector operations." kw:[vop] } // Compute the cummulative sum of sbp[dn]. Equivalent to Matlab cumsum(). diff --git a/src/vop/cmVectOpsTemplateMain.h b/src/vop/cmVectOpsTemplateMain.h index 4be3bb0..df36263 100644 --- a/src/vop/cmVectOpsTemplateMain.h +++ b/src/vop/cmVectOpsTemplateMain.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. // Float #include "cmVectOpsTemplateUndef.h" diff --git a/src/vop/cmVectOpsTemplateUndef.h b/src/vop/cmVectOpsTemplateUndef.h index 474a9e9..fba4ba9 100644 --- a/src/vop/cmVectOpsTemplateUndef.h +++ b/src/vop/cmVectOpsTemplateUndef.h @@ -1,3 +1,5 @@ +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. #ifdef VECT_OP_TYPE From 0e03acff01cffa28e03e1c13bf691ac1b7739af5 Mon Sep 17 00:00:00 2001 From: kevin Date: Thu, 15 Oct 2020 17:10:13 -0400 Subject: [PATCH 6/8] README.md : Added link to generated documentation. --- README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 2a987ef..f522dc3 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,9 @@ -libcm is a C application development framework with an emphasis on audio signal processing. +_libcm_ is a C application development framework with an emphasis on audio signal processing. + +There's a lot that could be said about this framework. The first is that it is quite large. +More than 150k lines at last count. The best way to get a sense of what is in it +is to browse the documentation files [here](https://currawongproject.org/static/doc/libcm/libcm.html). + + From d15e6a29ee96ad594a9eeea9eac08411d6afdf6a Mon Sep 17 00:00:00 2001 From: kevin Date: Fri, 16 Oct 2020 13:09:16 -0400 Subject: [PATCH 7/8] Documentation updates. --- doc/cdg_cfg.json | 3 +-- doc/cdg_code.css | 42 ++++++++++++++++++++++++++++++++++++---- doc/cdg_code_prefix.html | 36 ++++++++++++++++++++++++++++++++-- doc/cdg_div_cod.css | 24 ----------------------- doc/gen_doc.sh | 8 ++++++-- src/cmJson.c | 11 ++++------- src/cmLex.c | 9 +++------ src/cmSerialize.c | 12 ++++-------- src/cmSymTbl.c | 10 ++++------ src/cmVectOpsDocOut.h | 6 ++++-- src/dsp/cmDspBuiltIn.c | 1 + src/dsp/cmDspKr.c | 41 ++++++++++++++++++++------------------- src/dsp/cmDspKr.h | 6 +++++- 13 files changed, 125 insertions(+), 84 deletions(-) delete mode 100644 doc/cdg_div_cod.css diff --git a/doc/cdg_cfg.json b/doc/cdg_cfg.json index 67856c1..2c7e47c 100755 --- a/doc/cdg_cfg.json +++ b/doc/cdg_cfg.json @@ -85,7 +85,7 @@ "-fmarkdown" "-thtml5" "--css" - "cdg_div_cod.css" + "cdg_cod.css" "--css" "cdg_edoc.css" "--css" @@ -97,7 +97,6 @@ copy_files: [ - "cdg_div_cod.css" "cdg_edoc.css" "cdg_code.css" "style.css" diff --git a/doc/cdg_code.css b/doc/cdg_code.css index a10e708..f93f27d 100644 --- a/doc/cdg_code.css +++ b/doc/cdg_code.css @@ -1,9 +1,10 @@ -td.linenos { background-color: #fffff0; padding-right: 10px; } -span.lineno { background-color: #fffff0; padding: 0 5px 0 5px; } pre { line-height: 135%; } -body .hll { background-color: #ffffff; } -body { background: #f8f8f8; } +body { + background: #f0f0f0; + margin-left:2%; +} + body .c { color: firebrick; font-style: italic; } /* Comment */ body .k { color: #008000; font-weight: normal; } /* Keyword.Reserved */ body .p { color: #666666; } /* Operator */ @@ -28,3 +29,36 @@ body .a { font-wieght: bold; font-size: 120%; } + +.license { + color: #909090; + font-size:90%; + + padding:2%; + border: 1px solid #909090; +} + + +.cod pre { background: #f8f8f8; } +.cod pre .c { color: firebrick; font-weight: normal; } /* Comment */ +.cod pre .k { color: #008000; font-weight: normal; } /* Keyword.Reserved */ +.cod pre .p { color: #666666 } /* Operator */ +.cod pre .f { color: #000000; font-weight: normal; } /* Function */ +.cod pre .e { color: #000000; font-weight: normal; } /* enum */ +.cod pre .m { color: #008000; font-weight: normal; } /* macro */ +.cod pre .t { color: #008000; font-weight: normal; } /* typedef */ +.cod pre .i { color: #000000; font-weight: normal; } /* ident */ +.cod pre .l { color: #660066 } /* Literal */ +.cod pre .u { color: #000000 } + +.cod pre a:link {text-decoration:none; font-weight:500; } +.cod pre a:visited {text-decoration:none; font-weight:500; } +.cod pre a:hover {text-decoration:none; font-weight:700; } + +/* embedded pandoc comments */ +.cod pre .a { + border: 1px dotted gray; + background-color: #ececec; + color: #1111111; + padding: 0.5em; +} diff --git a/doc/cdg_code_prefix.html b/doc/cdg_code_prefix.html index c2c3661..e7e87b8 100755 --- a/doc/cdg_code_prefix.html +++ b/doc/cdg_code_prefix.html @@ -1,4 +1,4 @@ - + @@ -6,8 +6,40 @@ -
+ +
+

+ Copyright (C) Kevin Larke 2009-2020 +

+ +

+ This file is part of libcm. +

+ +

+ libcm is free software: you can redistribute it and/or modify it under + the terms of the GNU General Public License as published by the Free + Software Foundation, either version 3 of the License, or (at your + option) any later version. +

+ +

+ libcm is distributed in the hope that it will be useful, but WITHOUT + ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License + for more details. +

+ +

+ See the GNU General Public License distributed with the libcm + package or look here: . +

+ + +
+ +
diff --git a/doc/cdg_div_cod.css b/doc/cdg_div_cod.css deleted file mode 100644 index bff2ba6..0000000 --- a/doc/cdg_div_cod.css +++ /dev/null @@ -1,24 +0,0 @@ - - -.cod pre .c { color: firebrick; font-weight: normal; } /* Comment */ -.cod pre .k { color: #008000; font-weight: normal; } /* Keyword.Reserved */ -.cod pre .p { color: #666666 } /* Operator */ -.cod pre .f { color: #000000; font-weight: normal; } /* Function */ -.cod pre .e { color: #000000; font-weight: normal; } /* enum */ -.cod pre .m { color: #008000; font-weight: normal; } /* macro */ -.cod pre .t { color: #008000; font-weight: normal; } /* typedef */ -.cod pre .i { color: #000000; font-weight: normal; } /* ident */ -.cod pre .l { color: #660066 } /* Literal */ -.cod pre .u { color: #000000 } - -.cod pre a:link {text-decoration:none; font-weight:500; } -.cod pre a:visited {text-decoration:none; font-weight:500; } -.cod pre a:hover {text-decoration:none; font-weight:700; } - -/* embedded pandoc comments */ -.cod pre .a { - border: 1px dotted gray; - background-color: #ececec; - color: #1111111; - padding: 0.5em; -} diff --git a/doc/gen_doc.sh b/doc/gen_doc.sh index c126948..fc8a83e 100755 --- a/doc/gen_doc.sh +++ b/doc/gen_doc.sh @@ -14,7 +14,6 @@ gcc -E -C -P -traditional-cpp -o temp.h ../src/vop/cmVectOpsDoc.h sed 's/\(_##\)/_/g' temp.h > temp1.h # Remove header text generated by gcc. -# sed '/\/\*/,/\/\/end_cut/{#!d}' temp.h sed '/\/\*/,/\/\/end_cut/{//!d;};' temp1.h > temp2.h # Remove the first two lines. @@ -25,4 +24,9 @@ rm -f temp1.h rm -f temp2.h # Run the doc generator -#cdg -c cdg_cfg.json -o ~/temp/doc_libcm +# Note that we must use a full path to the 'cdg_cfg.json' file because it's +# absolute location must be determined to locate the full path to the source files. +~/src/dc/build/linux/debug/bin/cdg -c ~/src/libcm/doc/cdg_cfg.json -o ~/temp/doc2 + +# +scp ~/temp/doc2/* wf:webapps/currawongproject/htdocs/static/doc/libcm diff --git a/src/cmJson.c b/src/cmJson.c index 09e9ba7..0183870 100644 --- a/src/cmJson.c +++ b/src/cmJson.c @@ -3992,13 +3992,11 @@ void _cmJsonTestPrint( void* userPtr, const cmChar_t* text ) } -//{ { label:cmJsonEx } -//( +//( { label:cmJsonEx } +// // cmJsonTest() demonstrates some JSON tree operations. -//) - -//( -cmJsRC_t cmJsonTest( const char* fn, cmCtx_t* ctx ) +// +JsRC_t cmJsonTest( const char* fn, cmCtx_t* ctx ) { cmJsRC_t rc = kOkJsRC; cmJsRC_t rc1 = kOkJsRC; @@ -4080,4 +4078,3 @@ cmJsRC_t cmJsonTest( const char* fn, cmCtx_t* ctx ) return rc == kOkJsRC ? rc1 : rc; } //) -//} diff --git a/src/cmLex.c b/src/cmLex.c index 72fc480..776675f 100644 --- a/src/cmLex.c +++ b/src/cmLex.c @@ -909,12 +909,10 @@ const cmChar_t* cmLexRcToMsg( unsigned rc ) } -//{ { label:cmLexEx } -//( +//( { label:cmLexEx } +// // cmLexTest() gives a simple cmLex example. -//) - -//( +// void cmLexTest( cmRpt_t* rpt) { cmChar_t buf[] = @@ -983,4 +981,3 @@ void cmLexTest( cmRpt_t* rpt) } //) -//} diff --git a/src/cmSerialize.c b/src/cmSerialize.c index 7a0f2c6..2e53b85 100644 --- a/src/cmSerialize.c +++ b/src/cmSerialize.c @@ -1573,13 +1573,10 @@ const bool* cmSrRdBoolCV( cmSrH_t h, unsigned* eleCntPtr) return cmSrReadBoolCV(h,&valPtr,eleCntPtr) == kOkSrRC ? valPtr : NULL; } -//{ { label:cmSerialEx } -//( -// cmSrTest() is a serializer example function. -//) -//[ - +// +// cmSrTest() is a serializer example function. +// cmSrRC_t cmSrTest( cmCtx_t* ctx ) { unsigned i,j,k; @@ -1723,5 +1720,4 @@ cmSrRC_t cmSrTest( cmCtx_t* ctx ) return rc; } -//] -//} + diff --git a/src/cmSymTbl.c b/src/cmSymTbl.c index 78faf46..53652ca 100644 --- a/src/cmSymTbl.c +++ b/src/cmSymTbl.c @@ -352,12 +352,11 @@ void cmSymTblReport( cmSymTblH_t h ) } -//{ { label:cmSymTblEx } -//( +//( { label:cmSymTblEx } +// // cmSymTblTest() gives a usage example for the symbol table component. -//) +// -//[ void cmSymTblTest( cmCtx_t* ctx ) { unsigned baseSymId = 100; @@ -405,5 +404,4 @@ void cmSymTblTest( cmCtx_t* ctx ) return; } -//] -//} +//) diff --git a/src/cmVectOpsDocOut.h b/src/cmVectOpsDocOut.h index 71d05b2..a269402 100644 --- a/src/cmVectOpsDocOut.h +++ b/src/cmVectOpsDocOut.h @@ -1,7 +1,7 @@ -//| Copyright: (C) 2009-2020 Kevin Larke -//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { file_desc:"Math vector operations." kw:[vop math] } //) +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { label:misc desc:"Miscellaneous vector operations." kw:[vop] } // Compute the cummulative sum of sbp[dn]. Equivalent to Matlab cumsum(). @@ -719,6 +719,8 @@ void cmVOT_Interp1(T_t* y1, const T_t* x1, unsigned xy1N, const T_t* x0, const T //====================================================================================================================== //) +//| Copyright: (C) 2009-2020 Kevin Larke +//| License: GNU GPL version 3.0 or above. See the accompanying LICENSE file. //( { label:"Matrix ops" desc:"Common 2D matrix operations and accessors." kw:[vop] } diff --git a/src/dsp/cmDspBuiltIn.c b/src/dsp/cmDspBuiltIn.c index 11788f1..dc48465 100644 --- a/src/dsp/cmDspBuiltIn.c +++ b/src/dsp/cmDspBuiltIn.c @@ -54,6 +54,7 @@ //------------------------------------------------------------------------------------------------------------ //) + //( { label:cmDspPrinter file_desc:"Console printing unit." kw:[sunit] } enum { diff --git a/src/dsp/cmDspKr.c b/src/dsp/cmDspKr.c index 7832e4c..beae8aa 100644 --- a/src/dsp/cmDspKr.c +++ b/src/dsp/cmDspKr.c @@ -53,7 +53,8 @@ //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspKr file_desc:"Spectral non-linear distortion effect." kw:[sunit] } + +//( { label:cmDspKr file_desc:"Spectral non-linear distortion effect." kw:[sunit gutim] } enum { @@ -287,7 +288,7 @@ cmDspClass_t* cmKrClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspKr2 file_desc:"Spectral non-linear distortion effect." kw:[sunit] } +//( { label:cmDspKr2 file_desc:"Spectral non-linear distortion effect." kw:[sunit gutim] } enum { @@ -544,7 +545,7 @@ cmDspClass_t* cmKr2ClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspTimeLine file_desc:"Time line user interface unit." kw:[sunit] } +//( { label:cmDspTimeLine file_desc:"Time line user interface unit." kw:[sunit gutim] } enum { @@ -734,7 +735,7 @@ cmDspClass_t* cmTimeLineClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspScore file_desc:"Musical score user interface unit." kw:[sunit] } +//( { label:cmDspScore file_desc:"Musical score user interface unit." kw:[sunit gutim] } enum { @@ -931,7 +932,7 @@ cmDspClass_t* cmScoreClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspMidiFilePlay file_desc:"MIDI file player." kw:[sunit] } +//( { label:cmDspMidiFilePlay file_desc:"MIDI file player." kw:[sunit gutim] } enum { @@ -1173,7 +1174,7 @@ cmDspClass_t* cmMidiFilePlayClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspScFol file_desc:"MIDI performance score follower." kw:[sunit] } +//( { label:cmDspScFol file_desc:"MIDI performance score follower." kw:[sunit gutim] } enum { @@ -1491,7 +1492,7 @@ cmDspClass_t* cmScFolClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspScMod file_desc:"Score driven parameter automation." kw:[sunit] } +//( { label:cmDspScMod file_desc:"Score driven parameter automation." kw:[sunit gutim] } enum { @@ -1721,7 +1722,7 @@ cmDspClass_t* cmScModClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspGSwitch file_desc:"Route all inputs to one of a group of outputs." kw:[sunit] } +//( { label:cmDspGSwitch file_desc:"Route all inputs to one of a group of outputs." kw:[sunit gutim] } enum { @@ -1922,7 +1923,7 @@ cmDspClass_t* cmGSwitchClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspScaleRange file_desc:"Offset and scale a scalar value." kw:[sunit] } +//( { label:cmDspScaleRange file_desc:"Offset and scale a scalar value." kw:[sunit gutim] } enum { @@ -2025,7 +2026,7 @@ cmDspClass_t* cmScaleRangeClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspActiveMeas file_desc:"Issue stored parameter values at specified score locations." kw:[sunit] } +//( { label:cmDspActiveMeas file_desc:"Issue stored parameter values at specified score locations." kw:[sunit gutim] } enum { @@ -2412,7 +2413,7 @@ cmDspClass_t* cmActiveMeasClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspAmSync file_desc:"Calculate MIDI to Audio latency offsets." kw:[sunit] } +//( { label:cmDspAmSync file_desc:"Calculate MIDI to Audio latency offsets." kw:[sunit gutim] } // // // Usage: @@ -2690,7 +2691,7 @@ cmDspClass_t* cmAmSyncClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspNanoMap file_desc:"Control a MIDI synth." kw:[sunit] } +//( { label:cmDspNanoMap file_desc:"Control a MIDI synth." kw:[sunit gutim] } enum { @@ -2818,7 +2819,7 @@ cmDspClass_t* cmNanoMapClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspPicadae file_desc:"Control a MIDI synth." kw:[sunit] } +//( { label:cmDspPicadae file_desc:"Control the Picadae piano mechanism." kw:[sunit gutim] } enum { @@ -3253,7 +3254,7 @@ cmDspClass_t* cmPicadaeClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspRecdPlay file_desc:"Record audio segments from a live perfromance and play them back at a later time" kw:[sunit] } +//( { label:cmDspRecdPlay file_desc:"Record audio segments from a live perfromance and play them back at a later time" kw:[sunit gutim] } enum { @@ -3632,7 +3633,7 @@ cmDspClass_t* cmRecdPlayClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspGoertzel file_desc:"Goertzel tone detection filter" kw:[sunit] } +//( { label:cmDspGoertzel file_desc:"Goertzel tone detection filter" kw:[sunit gutim] } enum { kHopFactGrId, @@ -3809,7 +3810,7 @@ cmDspClass_t* cmGoertzelClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspSyncRecd file_desc:"Time align a MIDI and associated audio recording" kw:[sunit] } +//( { label:cmDspSyncRecd file_desc:"Time align a MIDI and associated audio recording" kw:[sunit gutim] } enum { @@ -4014,7 +4015,7 @@ cmDspClass_t* cmSyncRecdClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspTakeSeqBldr file_desc:"User interface unit for creating a single sequence from multiple, score aligned, MIDI fragments." kw:[sunit] } +//( { label:cmDspTakeSeqBldr file_desc:"User interface unit for creating a single sequence from multiple, score aligned, MIDI fragments." kw:[sunit gutim] } enum { @@ -4148,7 +4149,7 @@ cmDspClass_t* cmTakeSeqBldrClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspTakeSeqRend file_desc:"User interface unit for graphically rendering the MIDI sequences created by cmDspTakeSeqBldr." kw:[sunit] } +//( { label:cmDspTakeSeqRend file_desc:"User interface unit for graphically rendering the MIDI sequences created by cmDspTakeSeqBldr." kw:[sunit gutim] } enum { kBldrTsrId, @@ -4369,7 +4370,7 @@ cmDspClass_t* cmTakeSeqRendClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspReflectCalc file_desc:"Estimate the time-of-flight of from an acoustic signal from a speaker to a microphone." kw:[sunit] } +//( { label:cmDspReflectCalc file_desc:"Estimate the time-of-flight of from an acoustic signal from a speaker to a microphone." kw:[sunit gutim] } enum { kLfsrN_RcId, @@ -4527,7 +4528,7 @@ cmDspClass_t* cmReflectCalcClassCons( cmDspCtx_t* ctx ) //------------------------------------------------------------------------------------------------------------ //) -//( { label:cmDspEchoCancel file_desc:"Normalized least mean squares echo canceller." kw:[sunit] } +//( { label:cmDspEchoCancel file_desc:"Normalized least mean squares echo canceller." kw:[sunit gutim] } enum { kMuEcId, diff --git a/src/dsp/cmDspKr.h b/src/dsp/cmDspKr.h index 476fa83..ec9849b 100644 --- a/src/dsp/cmDspKr.h +++ b/src/dsp/cmDspKr.h @@ -7,6 +7,8 @@ extern "C" { #endif + //( { file_desc:"Dataflow process interface developed for GUTIM." kw:[snap gutim] } + struct cmDspClass_str* cmKrClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmKr2ClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmTimeLineClassCons( cmDspCtx_t* ctx ); @@ -27,7 +29,9 @@ extern "C" { struct cmDspClass_str* cmTakeSeqRendClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmReflectCalcClassCons( cmDspCtx_t* ctx ); struct cmDspClass_str* cmEchoCancelClassCons( cmDspCtx_t* ctx ); - + + //) + #ifdef __cplusplus } #endif From 889011801c75d3b8f736ed07bde634c8c55fec85 Mon Sep 17 00:00:00 2001 From: kevin Date: Fri, 16 Oct 2020 13:10:58 -0400 Subject: [PATCH 8/8] README.md : Updates --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f522dc3..4f95c64 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ _libcm_ is a C application development framework with an emphasis on audio signa There's a lot that could be said about this framework. The first is that it is quite large. More than 150k lines at last count. The best way to get a sense of what is in it -is to browse the documentation files [here](https://currawongproject.org/static/doc/libcm/libcm.html). +is to [browse the documentation files here](https://currawongproject.org/static/doc/libcm/libcm.html).