Object to interact with Matrix Manipulation Tool when it is active.
More...
|
void | loadMatrixFromFile (string filename) |
| Function to load an ITK transformation (.tfm) or a XML transformation (.xml) into current matrix. More...
|
|
void | saveMatrixToFile (string filename) |
| Function to save the current matrix as a transformation: ITK transformation (.tfm) or a XML transformation (.xml) More...
|
|
void | fillIdentity () |
| Function to set the current matrix to the identity matrix.
|
|
void | transpose () |
| Function to apply transpose operation to the current matrix.
|
|
void | inverse () |
| Function to apply inverse operation to the current matrix.
|
|
void | sumBy (double value) |
| Function to apply sum operation to the current matrix. More...
|
|
void | multiplyBy (double value) |
| Function to apply multiply operation to the current matrix. More...
|
|
void | swap () |
| Function to swap Matrix A with Matrix B.
|
|
void | clear () |
| Function to clear the current matrix by filling it with zeros.
|
|
void | concatenate () |
| Function to concatenate Matrix A and Matrix B using post-multiplication (A * B) and put the result in Matrix A. Matrix B will be set to the identity matrix.
|
|
void | round () |
| Function to round values in the current matrix to six decimal places.
|
|
void | sumMatrix () |
| Function to apply sum operation of Matrix A with Matrix B and set the result in Matrix A.
|
|
void | setMatrixFocus (int idx) |
| Function to set the focus on a matrix. More...
|
|
void | enableMatrixCalculation (bool toEnable) |
| Function to enable calculations between two matrices. More...
|
|
void | mergeTransform () |
| Function to combine an affine transformation matrix in Matrix A with one in Matrix B by multiplying their rotation and scaling transformations together and adding their translations, putting the result in Matrix A and the identity matrix in Matrix B.
|
|
|
double | getMatrixAt (int idx, int i, int j) |
| Function to get a single value from a matrix. More...
|
|
void | setMatrixAt (int idx, int i, int j, double val) |
| Function to set a single value to a matrix. More...
|
|
void | set3DMode () |
| Sets the dialog to use 3D matrix.
|
|
void | set2DMode () |
| Sets the dialog to use 2D matrix.
|
|
|
static TransformMatrix3D | MatrixTransform3DToMatrix3D (TransformFactory::AbstractMatrixTransformType::MatrixType &matrix, TransformFactory::AbstractMatrixTransformType::OutputVectorType &offset) |
| Function to get a 3D transformation matrix from a diferent representation of 3D transformation matrix and a offset vector. Conversion between diferent data types. More...
|
|
static TransformMatrix3D | MatrixTransform3DToMatrix3D (TransformFactory::AbstractMatrixTransformType::Pointer transform) |
| Function to get a 3D transformation matrix from a diferent representation of a 3D transformation. Conversion between diferent data types. More...
|
|
static TransformMatrix2D | MatrixTransform2DToMatrix2D (TransformFactory::AbstractMatrixTransformType2D::MatrixType &matrix, TransformFactory::AbstractMatrixTransformType2D::OutputVectorType &offset) |
| Function to get a 2D transformation matrix from a diferent representation of 2D transformation matrix and a offset vector. Conversion between diferent data types. More...
|
|
static TransformMatrix2D | MatrixTransform2DToMatrix2D (TransformFactory::AbstractMatrixTransformType2D::Pointer transform) |
| Function to get a 2D transformation matrix from a diferent representation of a 2D transformation. Conversion between diferent data types. More...
|
|
static TransformFactory::AffineType::Pointer | Matrix3DToTransform3D (TransformMatrix3D matrix) |
| Function to get a 3D affine transformation from a 3D transformation matrix. Conversion between diferent data types. More...
|
|
static TransformFactory::AffineType2D::Pointer | Matrix2DToTransform2D (TransformMatrix2D matrix) |
| Function to get a 2D affine transformation from a 2D transformation matrix. Conversion between diferent data types. More...
|
|
Object to interact with Matrix Manipulation Tool when it is active.
This object can be used to apply matrix operations when the Matrix Manipulation Tool window is loaded.
See also ScriptMaster::matrixManipulationTool() to obtain this object and MainWin::matrixManipulationTool() to enter the Matrix Manipulation Tool.
◆ enableMatrixCalculation
void enableMatrixCalculation |
( |
bool |
toEnable | ) |
|
|
slot |
Function to enable calculations between two matrices.
- Parameters
-
toEnable | True value indicates calculations are enabled. |
◆ getMatrixAt()
double getMatrixAt |
( |
int |
idx, |
|
|
int |
i, |
|
|
int |
j |
|
) |
| |
Function to get a single value from a matrix.
- Parameters
-
idx | Index of the matrix to get a value from (0 = Matrix A, 1 = Matrix B) |
i | Row index |
j | Column index |
- Returns
- The value [i, j] of corresponding matrix.
◆ loadMatrixFromFile
void loadMatrixFromFile |
( |
string |
filename | ) |
|
|
slot |
Function to load an ITK transformation (.tfm) or a XML transformation (.xml) into current matrix.
- Parameters
-
filename | Filename of ITK transformation (.tfm) or a XML transformation (.xml) file to load |
◆ Matrix2DToTransform2D()
static TransformFactory::AffineType2D::Pointer Matrix2DToTransform2D |
( |
TransformMatrix2D |
matrix | ) |
|
|
static |
Function to get a 2D affine transformation from a 2D transformation matrix. Conversion between diferent data types.
- Parameters
-
matrix | A 2D transformation matrix |
- Returns
- The 2D affine transformation
◆ Matrix3DToTransform3D()
static TransformFactory::AffineType::Pointer Matrix3DToTransform3D |
( |
TransformMatrix3D |
matrix | ) |
|
|
static |
Function to get a 3D affine transformation from a 3D transformation matrix. Conversion between diferent data types.
- Parameters
-
matrix | A 3D transformation matrix |
- Returns
- The 3D affine transformation
◆ MatrixTransform2DToMatrix2D() [1/2]
static TransformMatrix2D MatrixTransform2DToMatrix2D |
( |
TransformFactory::AbstractMatrixTransformType2D::MatrixType & |
matrix, |
|
|
TransformFactory::AbstractMatrixTransformType2D::OutputVectorType & |
offset |
|
) |
| |
|
static |
Function to get a 2D transformation matrix from a diferent representation of 2D transformation matrix and a offset vector. Conversion between diferent data types.
- Parameters
-
matrix | Transformation matrix |
offset | Offset vector |
- Returns
- The 2D transformation matrix
◆ MatrixTransform2DToMatrix2D() [2/2]
static TransformMatrix2D MatrixTransform2DToMatrix2D |
( |
TransformFactory::AbstractMatrixTransformType2D::Pointer |
transform | ) |
|
|
static |
Function to get a 2D transformation matrix from a diferent representation of a 2D transformation. Conversion between diferent data types.
- Parameters
-
transform | A 2D transformation |
- Returns
- The 2D transformation matrix
◆ MatrixTransform3DToMatrix3D() [1/2]
static TransformMatrix3D MatrixTransform3DToMatrix3D |
( |
TransformFactory::AbstractMatrixTransformType::MatrixType & |
matrix, |
|
|
TransformFactory::AbstractMatrixTransformType::OutputVectorType & |
offset |
|
) |
| |
|
static |
Function to get a 3D transformation matrix from a diferent representation of 3D transformation matrix and a offset vector. Conversion between diferent data types.
- Parameters
-
matrix | Transformation matrix |
offset | Offset vector |
- Returns
- The 3D transformation matrix
◆ MatrixTransform3DToMatrix3D() [2/2]
static TransformMatrix3D MatrixTransform3DToMatrix3D |
( |
TransformFactory::AbstractMatrixTransformType::Pointer |
transform | ) |
|
|
static |
Function to get a 3D transformation matrix from a diferent representation of a 3D transformation. Conversion between diferent data types.
- Parameters
-
transform | A 3D transformation |
- Returns
- The 3D transformation matrix
◆ multiplyBy
void multiplyBy |
( |
double |
value | ) |
|
|
slot |
Function to apply multiply operation to the current matrix.
- Parameters
-
value | Value that every cell will be multiplied by |
◆ saveMatrixToFile
void saveMatrixToFile |
( |
string |
filename | ) |
|
|
slot |
Function to save the current matrix as a transformation: ITK transformation (.tfm) or a XML transformation (.xml)
- Parameters
-
filename | Filename of ITK transformation (.tfm) or a XML transformation (.xml) file to save |
◆ setMatrixAt()
void setMatrixAt |
( |
int |
idx, |
|
|
int |
i, |
|
|
int |
j, |
|
|
double |
val |
|
) |
| |
Function to set a single value to a matrix.
- Parameters
-
idx | Index of the matrix to set a value to (0 = Matrix A, 1 = Matrix B) |
i | Row index |
j | Column index |
val | Value to set in [i, j] of corresponding matrix |
◆ setMatrixFocus
void setMatrixFocus |
( |
int |
idx | ) |
|
|
slot |
Function to set the focus on a matrix.
- Parameters
-
idx | Index of the matrix to set the focus on (0 = Matrix A, 1 = Matrix B) |
◆ sumBy
void sumBy |
( |
double |
value | ) |
|
|
slot |
Function to apply sum operation to the current matrix.
- Parameters
-
value | Value that will be added to every cell |