]> Creatis software - creaRigidRegistration.git/blob - PackRecalage/src/bbPackRecalageTransform2DBox.h
3d9dbbb62525f00ee0a0bb30da384d75418de222
[creaRigidRegistration.git] / PackRecalage / src / bbPackRecalageTransform2DBox.h
1 #ifndef __bbPackRecalageTransform2DBox_h_INCLUDED__
2 #define __bbPackRecalageTransform2DBox_h_INCLUDED__
3 #include "bbPackRecalage_EXPORT.h"
4 #include "bbtkAtomicBlackBox.h"
5 #include "iostream"
6
7 #include "vtkLinearTransform.h"
8 #include "Transformer.h"
9
10 namespace bbPackRecalage
11 {
12
13 class bbPackRecalage_EXPORT Transform2DBox
14  : 
15    public bbtk::AtomicBlackBox
16 {
17                 BBTK_BLACK_BOX_INTERFACE(Transform2DBox,bbtk::AtomicBlackBox);
18                 /*Point(x,y) -> Rotation Center*/
19                 BBTK_DECLARE_INPUT(CenterPoint,std::vector<int>);
20
21                 /*Rotation angle*/
22                 BBTK_DECLARE_INPUT(Angle,double);
23
24                 
25                 /*Scalation to be done in the x axis*/
26                 BBTK_DECLARE_INPUT(ScaleX,double);
27
28                 
29                 /*Scalation to be done in the y axis*/
30                 BBTK_DECLARE_INPUT(ScaleY,double);
31
32                 /*Scalation to be done in the z axis*/
33                 BBTK_DECLARE_INPUT(ScaleZ,double);
34
35                 /*Resultant vtkTransform*/
36                 BBTK_DECLARE_OUTPUT(Out, vtkTransform*);
37
38                 BBTK_PROCESS(Process);
39                 void Process();
40                 
41                 /*Class in charge of making the transformations*/
42                 Transformer *transformer;               
43 };
44
45 BBTK_BEGIN_DESCRIBE_BLACK_BOX(Transform2DBox,bbtk::AtomicBlackBox);
46 BBTK_NAME("Transform2DBox");
47 BBTK_AUTHOR("va-perez@uniandes.edu.co");
48 BBTK_DESCRIPTION("Given 2 points and an angle, it calculates the vtkTransform result after aplying the transformations, using the first point as base of the transformation");
49 BBTK_CATEGORY("filter");
50 BBTK_INPUT(Transform2DBox,CenterPoint,"Point (x,y,z) -> Rotation Center",std::vector<int>,"");
51 BBTK_INPUT(Transform2DBox,Angle,"Rotation Angle",double,"");
52 BBTK_INPUT(Transform2DBox,ScaleX,"Scale in X",double,"");
53 BBTK_INPUT(Transform2DBox,ScaleY,"Scale in Y",double,"");
54 BBTK_INPUT(Transform2DBox,ScaleZ,"Scale in Z",double,"");
55 BBTK_OUTPUT(Transform2DBox,Out,"Linear Transform filter",vtkTransform*,"");
56 BBTK_END_DESCRIBE_BLACK_BOX(Transform2DBox);
57 }
58 // EO namespace bbPackRecalage
59
60 #endif // __bbPackRecalageTransform2DBox_h_INCLUDED__
61