Jamoma API  0.6.0.a19
TTSpatDBAPRenderer.h
Go to the documentation of this file.
1 /** @file
2  *
3  * @ingroup dspSpatLib
4  *
5  * @brief A basic proof-of-concept spatial renderer where the audio of a source will snap to the nearest sink.
6  *
7  * @details
8  *
9  * @todo: Extend with a solution for interpolating to new matrix coefficients
10  *
11  * @authors Trond Lossius, Nils Peters, Timothy Place
12  *
13  * @copyright Copyright © 2011 by Trond Lossius, Nils Peters, and Timothy Place @n
14  * This code is licensed under the terms of the "New BSD License" @n
15  * http://creativecommons.org/licenses/BSD/
16  */
17 
18 
19 #ifndef __SPATDBAPRENDERER_H__
20 #define __SPATDBAPRENDERER_H__
21 
22 #include "TTDSP.h"
23 #include "TTSampleMatrix.h"
24 #include "TTSpatEntity.h"
25 #include "TTSpatBaseRenderer.h"
26 #include "TTSpatDBAPSource.h"
27 
28 
29 /** TTSpatDBAPRenderer contains attributes and methods that are specific to this particular spatialisation renderer.
30  */
32 
33 public:
34 
35  TTSampleMatrixPtr mMixerMatrixCoefficients; ///< A matrix holding all coefficient for matrix-based mixing of sources to sinks.
36  TTFloat64 mRolloff; ///< global
37 
38 
39  /** Constructor
40  */
42 
43 
44  /** Destructor
45  */
47 
48  /** This method is called whenever matrix coefficients need to be updated.
49  @details This method also takes care of matrix resizing if the number of sources or sinks change.
50  @param sources A vector of sources
51  @param sinks A vector of sinks
52  */
54 
55 
56  // TODO: make these accessors non-inlined
57  TTFloat64 getRolloff()
58  {
59  return mRolloff;
60  }
61 
62  // TODO: document that caller must then call recalculateMatrixCoefficients() to update the matrix
63  void setRolloff(TTFloat64 aRolloff);
64 
65 };
66 
67 
68 #endif // __SPATDBAPRENDERER_H__
A basic proof-of-concept spatial renderer where the audio of a source will snap to the nearest sink...
TTSpatDBAPRenderer contains attributes and methods that are specific to this particular spatialisatio...
TTSpatEntity describes the geometry of a point, and TTSpatSource and TTSpatSink specialise this furth...
TTSampleMatrix holds some audio in a chunk of memory.
Jamoma DSP Library.
double TTFloat64
64 bit floating point number
Definition: TTBase.h:188
Container object that holds some audio in a chunk of memory.
~TTSpatDBAPRenderer()
Destructor.
void recalculateMatrixCoefficients(TTSpatSourceVector &aSources, TTSpatSinkVector &aSinks)
This method is called whenever matrix coefficients need to be updated.
TTSampleMatrixPtr mMixerMatrixCoefficients
A matrix holding all coefficient for matrix-based mixing of sources to sinks.
TTSpatDBAPRenderer()
Constructor.
std::vector< TTSpatSource > TTSpatSourceVector
Pointer to a vector of TTSpatSource points.
Definition: TTSpatEntity.h:108
std::vector< TTSpatSink > TTSpatSinkVector
Pointer to a vector of TTSpatSink points.
Definition: TTSpatEntity.h:114
The #TTSpatDBAPSource class provides an extended description of a source as compared to the TTSpatSou...
TTSpatBaseRenderer defines the basic interface from which all renderers inherit.
TTFloat64 mRolloff
global