Jamoma API  0.6.0.a19
TTMatrixGain.h
1 /*
2  * Jamoma MatrixProcessingLib: Gain
3  * Copyright © 2011, Timothy Place
4  *
5  * License: This code is licensed under the terms of the "New BSD License"
6  * http://creativecommons.org/licenses/BSD/
7  */
8 
9 #ifndef __TTMATRIXGAIN_H__
10 #define __TTMATRIXGAIN_H__
11 
12 #include "TTMatrixProcessingLib.h"
13 
14 
15 /****************************************************************************************************/
16 // Class Specifications
17 
18 /**
19  This class scales all of the values in a matrix to produce an output matrix.
20 
21  The trivial nature of this operation could possibly be combined in the the gain class in the Jamoma DSP library.
22  It is probably worth considering doing this for a variety of classes.
23 
24  However, this simple class is useful in that it provides a testbed for basic matrix operation.
25  */
28 
29 
30  TTFloat64 mGain; // attribute: factor by which to scale matrix values
31 
32 
33  /** Calculate matrix output using an average of the stencil. */
34  TTErr matrixCalculateGain(TTMatrixArray& inputMatrices, TTMatrixArray& outputMatrices);
35 
36  template<typename T>
37  TTErr doCalculateGain(const TTMatrixBasePtr inMatrix, TTMatrixBasePtr outMatrix);
38 
39  /** Unit Tests */
40  virtual TTErr test(TTValue& returnedTestInfo);
41 };
42 
43 
44 #endif // __TTMATRIXGAIN_H__
This class scales all of the values in a matrix to produce an output matrix.
Definition: TTMatrixGain.h:26
TTDataObjectBase is the base class for all data generating and processing objects.
double TTFloat64
64 bit floating point number
Definition: TTBase.h:188
#define TTCLASS_SETUP(className)
TODO Doxygen: need more comments here.
Definition: TTFoundation.h:54
2-dimensional matrix of compound values with N elements each.
Definition: TTMatrixBase.h:41
An array of TTMatrix instance pointers.
Definition: TTMatrixArray.h:25
TTErr
Jamoma Error Codes Enumeration of error codes that might be returned by any of the TTBlue functions a...
Definition: TTBase.h:342
[doxygenAppendixC_copyExample]
Definition: TTValue.h:34