Jamoma API  0.6.0.a19
TTMatrix.cpp
Go to the documentation of this file.
1 /** @file
2  *
3  * @ingroup foundationLibrary
4  *
5  * @brief Create Jamoma object instances.
6  *
7  * @author Timothy Place
8  *
9  * @copyright Copyright © 2014, Timothy Place @n
10  * This code is licensed under the terms of the "New BSD License" @n
11  * http://creativecommons.org/licenses/BSD/
12  */
13 
14 #include "TTMatrix.h"
15 #include "TTMatrixBase.h"
16 
17 
19 {
20  instance()->clear();
21 }
22 
23 
25 {
26  instance()->referenceExternalData(aDataPointer);
27 }
28 
29 
31 {
32  return instance()->getLockedPointer();
33 }
34 
35 
37 {
39 }
40 
41 
43 {
44  return instance()->getRowCount();
45 }
46 
47 
49 {
50  return instance()->getColumnCount();
51 }
52 
53 
55 {
56  return instance()->getComponentStride();
57 }
58 
59 
2-dimensional matrix of compound values with N elements each.
TTBytePtr getLockedPointer()
Return a pointer to the matrix data, and lock the matrix so that others cannot access the data...
Definition: TTMatrixBase.h:547
TTByte * getLockedPointer()
Return a pointer to the matrix data, and lock the matrix so that others cannot access the data...
Definition: TTMatrix.cpp:30
TTErr clear()
Set every element in the matrix to zero.
void releaseLockedPointer()
Release a locked pointer obtained using getLockedPointer().
Definition: TTMatrix.cpp:36
TTColumnID getColumnCount()
Simple data accessor.
Definition: TTMatrixBase.h:154
TTInt32 TTColumnID
Datatype for any number used to indicate a column index within the matrix.
Definition: TTBase.h:216
TTUInt32 getComponentStride() const
Return number of bytes from one the beginning one matrix component to the next.
Definition: TTMatrix.cpp:54
TTUInt32 getComponentStride()
Simple data accessor.
Definition: TTMatrixBase.h:210
TTMatrixBase * instance() const
Get a pointer to the wrapped TTMatrixBase instance.
Definition: TTMatrix.h:37
TTInt32 TTRowID
Datatype for any number used to indicate a row index within a matrix.
Definition: TTBase.h:207
TTRowID getRowCount() const
Number of rows in the matrix.
Definition: TTMatrix.cpp:42
void * TTPtr
A generic pointer.
Definition: TTBase.h:248
TTRowID getRowCount()
Simple data accessor.
Definition: TTMatrixBase.h:147
TTColumnID getColumnCount() const
Number of columns in the matrix.
Definition: TTMatrix.cpp:48
TTMatrix wraps a TTMatrixBase for use.
void referenceExternalData(TTPtr aDataPointer)
You must proceed to set the various attributes, dimensions, etc.
Definition: TTMatrixBase.h:534
unsigned char TTByte
Byte value.
Definition: TTBase.h:168
void releaseLockedPointer()
Release a locked pointer obtained using getLockedPointer().
Definition: TTMatrixBase.h:556
std::uint32_t TTUInt32
32 bit unsigned integer
Definition: TTBase.h:178
void referenceExternalData(TTPtr aDataPointer)
You must proceed to set the various attributes, dimensions, etc.
Definition: TTMatrix.cpp:24
void clear()
Set all components of a matrix to zero.
Definition: TTMatrix.cpp:18