From 628ffd12c8c2b53346866015dae6603e37643be3 Mon Sep 17 00:00:00 2001 From: reyes Date: Tue, 31 May 2011 15:43:24 +0000 Subject: [PATCH] *** empty log message *** --- packages/vtk/src/bbvtkSimpleMathematics.h | 64 +++++++++++++++++++++++ 1 file changed, 64 insertions(+) create mode 100644 packages/vtk/src/bbvtkSimpleMathematics.h diff --git a/packages/vtk/src/bbvtkSimpleMathematics.h b/packages/vtk/src/bbvtkSimpleMathematics.h new file mode 100644 index 0000000..63a8eec --- /dev/null +++ b/packages/vtk/src/bbvtkSimpleMathematics.h @@ -0,0 +1,64 @@ +#ifndef __bbvtkSimpleMathematics_h_INCLUDED__ +#define __bbvtkSimpleMathematics_h_INCLUDED__ +#include "bbvtk_EXPORT.h" +#include "bbtkAtomicBlackBox.h" +#include "iostream" + +#include +#include +#include +#include + + +namespace bbvtk +{ + + +class StaticLecture +{ +public: + void setPixelValue(int i, int j, int k, vtkImageData* img, double value); + double getPixelValue(int i, int j, int k, vtkImageData* img); +}; + + +class bbvtk_EXPORT SimpleMathematics + : + public bbtk::AtomicBlackBox +{ + BBTK_BLACK_BOX_INTERFACE(SimpleMathematics,bbtk::AtomicBlackBox); + BBTK_DECLARE_INPUT(In1,vtkImageData*); + BBTK_DECLARE_INPUT(In2,vtkImageData*); + BBTK_DECLARE_INPUT(Operation,int); + BBTK_DECLARE_INPUT(InConstant,double); + BBTK_DECLARE_OUTPUT(Out,vtkImageData*); + BBTK_PROCESS(Process); + void Process(); + + void crearPredeterminado(); + void substractWithMinimum(); + void MultiplyBy(); + + StaticLecture lector; + + vtkImageMathematics* ope; + vtkImageData* constante; +}; + +BBTK_BEGIN_DESCRIBE_BLACK_BOX(SimpleMathematics,bbtk::AtomicBlackBox); +BBTK_NAME("SimpleMathematics"); +BBTK_AUTHOR("_author_"); +BBTK_DESCRIPTION("_description_"); +BBTK_CATEGORY("__CATEGORY__"); +BBTK_INPUT(SimpleMathematics,In1,"",vtkImageData*,""); +BBTK_INPUT(SimpleMathematics,In2,"",vtkImageData*,""); +BBTK_INPUT(SimpleMathematics,InConstant,"",double,""); +BBTK_INPUT(SimpleMathematics,Operation,"0:Add, 1:subtract, 2:multiply, 3:divide, 4:invert, 5:sin, 6:cos, 7:exp, 8:log, 9:abs",int,""); +BBTK_OUTPUT(SimpleMathematics,Out,"",vtkImageData*,""); +BBTK_END_DESCRIBE_BLACK_BOX(SimpleMathematics); +} +// EO namespace bbSimpleProcessing + +#endif // __bbvtkSimpleMathematics_h_INCLUDED__ + + -- 2.47.1