00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00048 #ifdef _USE_VTK_
00049
00050
00051 #ifndef __bbvtkMIPCreator_h_INCLUDED__
00052 #define __bbvtkMIPCreator_h_INCLUDED__
00053
00054
00055 #include "bbtkAtomicBlackBox.h"
00056
00057 #include "vtkImageData.h"
00058 #include <vtkImageShiftScale.h>
00059 #include <vtkVolumeRayCastMIPFunction.h>
00060 #include <vtkVolumeRayCastMapper.h>
00061 #include "vtkProp3D.h"
00062 #include "vtkVolume.h"
00063
00064 namespace bbvtk
00065 {
00066
00067
00068
00069 class MIPCreator : public bbtk::AtomicBlackBox
00070 {
00071 public:
00072 BBTK_BLACK_BOX_INTERFACE(MIPCreator,bbtk::AtomicBlackBox);
00073
00074 BBTK_DECLARE_INPUT(In,vtkImageData *);
00075 BBTK_DECLARE_INPUT(Shift,int);
00076 BBTK_DECLARE_INPUT(Scale,float);
00077 BBTK_DECLARE_OUTPUT(Out,vtkProp3D*);
00078 BBTK_PROCESS(Process);
00079 void Process();
00080
00081 protected:
00082 virtual void bbUserConstructor();
00083 virtual void bbUserCopyConstructor();
00084 virtual void bbUserDestructor();
00085 void Init();
00086 private:
00087 vtkImageShiftScale* mCast;
00088 vtkVolumeRayCastMIPFunction* mMIP;
00089 vtkVolumeRayCastMapper* mMapper;
00090 vtkVolume* mVolume;
00091 };
00092
00093
00094
00095 BBTK_BEGIN_DESCRIBE_BLACK_BOX(MIPCreator,bbtk::AtomicBlackBox);
00096 BBTK_NAME("MIPCreator");
00097 BBTK_AUTHOR("laurent.guigues@creatis.insa-lyon.fr");
00098 BBTK_DESCRIPTION("Creates a Maximum Intensity Projection (MIP) view of a 3D image. Creates a vtkProp3D object to insert into a 3D scene (e.g. a Viewer3D)");
00099 BBTK_CATEGORY("3D object creator");
00100 BBTK_INPUT(MIPCreator,Shift,"Gray scale shift",int,"");
00101 BBTK_INPUT(MIPCreator,Scale,"Gray scale scaling",float,"");
00102 BBTK_INPUT(MIPCreator,In,"Input Image",vtkImageData *,"");
00103 BBTK_OUTPUT(MIPCreator,Out,"MIP object to plug into a 3D viewer",vtkProp3D*,"");
00104 BBTK_END_DESCRIBE_BLACK_BOX(MIPCreator);
00105
00106
00107
00108 }
00109
00110 #endif //__bbtvtkMIPCreator_h__
00111
00112 #endif //_USE_VTK_
00113