TransformationType.h
1 /*
2  * Medical Image Registration ToolKit ()
3  *
4  * Copyright 2008-2015 Imperial College London
5  * Copyright 2008-2013 Daniel Rueckert, Julia Schnabel
6  * Copyright 2013-2015 Andreas Schuh
7  *
8  * Licensed under the Apache License, Version 2.0 (the "License");
9  * you may not use this file except in compliance with the License.
10  * You may obtain a copy of the License at
11  *
12  * http://www.apache.org/licenses/LICENSE-2.0
13  *
14  * Unless required by applicable law or agreed to in writing, software
15  * distributed under the License is distributed on an "AS IS" BASIS,
16  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17  * See the License for the specific language governing permissions and
18  * limitations under the License.
19  */
20 
21 #ifndef MIRTK_TransformationType_H
22 #define MIRTK_TransformationType_H
23 
24 
25 namespace mirtk {
26 
27 
28 /// Enumeration of transformation types
29 ///
30 /// Each transformation class has its own enumeration value which is written
31 /// to the transformation file right after the magic number. Different versions
32 /// are distinguished by different type IDs.
33 ///
34 /// Enumeration values 50-60 were assigned to the refactored FFD types
35 /// which store the control point data in an instance of GenericImage.
36 ///
37 /// Enumeration values 70-80 were assigned to the refactored FFD types
38 /// which store also the method used to extrapolate control point coefficients
39 /// outside the finite discrete lattice on which the FFD is defined.
40 ///
41 /// \attention Do not change the enumeration value of existing entries as then
42 /// already saved transformation files are not identified correctly.
43 /// To yet allow a better ordering of the entries, the enumeration
44 /// values are thus assigned explicitly, also to remind of this.
46 {
47  TRANSFORMATION_MAGIC = 815007,
48  TRANSFORMATION_UNKNOWN = 0,
49  // linear transformations
50  TRANSFORMATION_HOMOGENEOUS = 1,
51  TRANSFORMATION_RIGID = 2,
52  TRANSFORMATION_SIMILARITY = 22,
53  TRANSFORMATION_AFFINE = 3,
54  TRANSFORMATION_HOMO_TEMPORAL = 30,
55  TRANSFORMATION_RIGID_TEMPORAL = 31,
56  TRANSFORMATION_AFFINE_TEMPORAL = 32,
57  // linear FFD
58  TRANSFORMATION_LINEAR_FFD_2D_v1 = 70,
59  TRANSFORMATION_LINEAR_FFD_2D = TRANSFORMATION_LINEAR_FFD_2D_v1,
60  TRANSFORMATION_LINEAR_FFD_3D_v1 = 5,
61  TRANSFORMATION_LINEAR_FFD_3D_v2 = 13,
62  TRANSFORMATION_LINEAR_FFD_3D_v3 = 51,
63  TRANSFORMATION_LINEAR_FFD_3D_v4 = 71,
64  TRANSFORMATION_LINEAR_FFD_3D = TRANSFORMATION_LINEAR_FFD_3D_v4,
65  TRANSFORMATION_LINEAR_FFD_4D_v1 = 17,
66  TRANSFORMATION_LINEAR_FFD_4D_v2 = 52,
67  TRANSFORMATION_LINEAR_FFD_4D_v3 = 72,
68  TRANSFORMATION_LINEAR_FFD_4D = TRANSFORMATION_LINEAR_FFD_4D_v3,
69  TRANSFORMATION_LINEAR_FFD_SV_v1 = 73,
70  TRANSFORMATION_LINEAR_FFD_SV = TRANSFORMATION_LINEAR_FFD_SV_v1,
71  TRANSFORMATION_LINEAR_FFD_TD_v1 = 18,
72  TRANSFORMATION_LINEAR_FFD_TD_v2 = 54,
73  TRANSFORMATION_LINEAR_FFD_TD_v3 = 74,
74  TRANSFORMATION_LINEAR_FFD_TD = TRANSFORMATION_LINEAR_FFD_TD_v3,
75  // B-spline FFD
76  TRANSFORMATION_BSPLINE_FFD_2D_v1 = 75,
77  TRANSFORMATION_BSPLINE_FFD_3D_v1 = 4,
78  TRANSFORMATION_BSPLINE_FFD_3D_v2 = 12,
79  TRANSFORMATION_BSPLINE_FFD_3D_v3 = 56,
80  TRANSFORMATION_BSPLINE_FFD_3D_v4 = 76,
81  TRANSFORMATION_BSPLINE_FFD_3D = TRANSFORMATION_BSPLINE_FFD_3D_v4,
82  TRANSFORMATION_BSPLINE_FFD_4D_v1 = 14,
83  TRANSFORMATION_BSPLINE_FFD_4D_v2 = 57,
84  TRANSFORMATION_BSPLINE_FFD_4D_v3 = 77,
85  TRANSFORMATION_BSPLINE_FFD_4D = TRANSFORMATION_BSPLINE_FFD_4D_v3,
86  TRANSFORMATION_BSPLINE_FFD_SV_v1 = 16,
87  TRANSFORMATION_BSPLINE_FFD_SV_v2 = 23,
88  TRANSFORMATION_BSPLINE_FFD_SV_v3 = 24,
89  TRANSFORMATION_BSPLINE_FFD_SV_v4 = 25,
90  TRANSFORMATION_BSPLINE_FFD_SV_v5 = 27,
91  TRANSFORMATION_BSPLINE_FFD_SV_v6 = 58,
92  TRANSFORMATION_BSPLINE_FFD_SV_v7 = 65,
93  TRANSFORMATION_BSPLINE_FFD_SV_v8 = 78,
94  TRANSFORMATION_BSPLINE_FFD_SV = TRANSFORMATION_BSPLINE_FFD_SV_v8,
95  TRANSFORMATION_BSPLINE_FFD_TD_v1 = 15,
96  TRANSFORMATION_BSPLINE_FFD_TD_v2 = 21,
97  TRANSFORMATION_BSPLINE_FFD_TD_v3 = 59,
98  TRANSFORMATION_BSPLINE_FFD_TD_v4 = 79,
99  TRANSFORMATION_BSPLINE_FFD_TD = TRANSFORMATION_BSPLINE_FFD_TD_v4,
100  // "decorating" transformations
101  TRANSFORMATION_BSPLINE_FFD_STATISTICAL = 61,
102  // composite transformations
103  TRANSFORMATION_MFFD = 7,
104  TRANSFORMATION_FLUID_v1 = 8,
105  TRANSFORMATION_FLUID_v2 = 81,
106  TRANSFORMATION_FLUID = TRANSFORMATION_FLUID_v2,
107  TRANSFORMATION_MFFD_SV = 26,
108  // others not included in MIRTK (cf. BioMedIA/IRTK)
109  TRANSFORMATION_LATTICE_FFD = 9,
110  TRANSFORMATION_MULTI_FRAME_LATTICE_FFD = 10,
111  TRANSFORMATION_QUATERNION = 11,
112  TRANSFORMATION_EIGEN_FFD_3D_v1 = 6,
113  TRANSFORMATION_EIGEN_FFD_3D_v2 = 60,
114  TRANSFORMATION_EIGEN_FFD_3D_v3 = 80,
115  TRANSFORMATION_EIGEN_FFD_3D = TRANSFORMATION_EIGEN_FFD_3D_v3,
116  TRANSFORMATION_PERIODIC_v1 = 20, // obsolete
117  TRANSFORMATION_PERIODIC = TRANSFORMATION_PERIODIC_v1
118 };
119 
120 
121 } // namespace mirtk
122 
123 #endif // MIRTK_TransformationType_H
Definition: IOConfig.h:41