]> Creatis software - bbtk.git/blob - packages/vtk/src/bbvtkBinaryOperations.h
623d03923a20a3c473116c3a83f0844514eca8f5
[bbtk.git] / packages / vtk / src / bbvtkBinaryOperations.h
1 #ifndef __bbvtkBinaryOperations_h_INCLUDED__
2 #define __bbvtkBinaryOperations_h_INCLUDED__
3 #include "bbvtk_EXPORT.h"
4 #include "bbtkAtomicBlackBox.h"
5 #include "iostream"
6 #include "bbtkStaticLecture.h"
7
8
9 #include <vtkImageMathematics.h>
10 #include <vtkImageData.h>
11 #include <vtkType.h>
12 #include <vtkImageData.h>
13
14
15 namespace bbvtk
16 {
17
18
19
20 class bbvtk_EXPORT BinaryOperations
21  :
22    public bbtk::AtomicBlackBox
23 {
24   BBTK_BLACK_BOX_INTERFACE(BinaryOperations,bbtk::AtomicBlackBox);
25   BBTK_DECLARE_INPUT(In1,vtkImageData*);
26   BBTK_DECLARE_INPUT(In2,vtkImageData*);
27   BBTK_DECLARE_INPUT(Operation,int);
28   BBTK_DECLARE_OUTPUT(Out,vtkImageData*);
29   BBTK_PROCESS(Process);
30   void Process();
31
32   void crearPredeterminado();
33   void substractWithMinimum();
34   void MultiplyBy();
35
36   bbtkStaticLecture lector;
37
38   vtkImageMathematics* ope;
39   vtkImageData* constante;
40 };
41
42 BBTK_BEGIN_DESCRIBE_BLACK_BOX(BinaryOperations,bbtk::AtomicBlackBox);
43 BBTK_NAME("BinaryOperations");
44 BBTK_AUTHOR("Info-Dev");
45 BBTK_DESCRIPTION("Math operation between two images");
46 BBTK_CATEGORY("filter");
47 BBTK_INPUT(BinaryOperations,In1,"",vtkImageData*,"");
48 BBTK_INPUT(BinaryOperations,In2,"",vtkImageData*,"");
49 BBTK_INPUT(BinaryOperations,Operation,"0:Add (default) , 1:subtract, 2:multiply, 3:divide",int,"");
50 BBTK_OUTPUT(BinaryOperations,Out,"",vtkImageData*,"");
51 BBTK_END_DESCRIBE_BLACK_BOX(BinaryOperations);
52 }
53 // EO namespace bbSimpleProcessing
54
55 #endif // __bbvtkBinaryOperations_h_INCLUDED__
56
57