Class f3d::transform2d_t
Definition: types.h
(line 217)
Store a 3x3 transform matrix as a sequence of 9 float values VTK expects a 4x4 matrix, but for 2d transforms this is exposed as a 3x3 matrix
Inherits from:
Members
- Array
- data
- double_array_t
- operator!=
- operator==
- operator[]
- transform2d_t
- transform2d_t
- transform2d_t
- transform2d_t
- transform2d_t
Public functions
Function transform2d_t
f3d::transform2d_t::transform2d_t()=default
Return type:
Function transform2d_t
f3d::transform2d_t::transform2d_t(const std::vector< double > &vec)
Parameters:
- const std::vector< double > & vec
Return type:
Function transform2d_t
f3d::transform2d_t::transform2d_t(const std::initializer_list< double > &list)
Parameters:
- const std::initializer_list< double > & list
Return type:
Function transform2d_t
f3d::transform2d_t::transform2d_t(double M1_1, double M1_2, double M1_3, double M2_1, double M2_2, double M2_3, double M3_1, double M3_2, double M3_3)
The variables of this function are based on the mathematical notation for matrices, where the coordinates correspond to the following:
[M1_1, M1_2, M1_3]
M = [M2_1, M2_2, M2_3]
[M3_1, M3_2, M3_3]
Parameters:
- double M1_1
- double M1_2
- double M1_3
- double M2_1
- double M2_2
- double M2_3
- double M3_1
- double M3_2
- double M3_3
Return type:
Function transform2d_t
F3D_EXPORT f3d::transform2d_t::transform2d_t(const double_array_t< 2 > &scale, const double_array_t< 2 > &translate, const angle_deg_t &angleRad)
The general form of a 3x3 transformation matrix M with scale S(x,y), translation T(x,y), and angle a (in degrees), is solved out to the following:
[cos(a)*S(x), -sin(a)*S(y), T(x)]
M = [sin(a)*S(x), cos(a)*S(y), T(y)]
[0, 0, 1 ]
Using this formula, we fill each cell using the values in the constructor
Parameters:
- const double_array_t< 2 > & scale
- const double_array_t< 2 > & translate
- const angle_deg_t & angleRad
Return type: F3D_EXPORT