--- /dev/null
+#include "bbcreaMaracasVisuCutModule2.h"
+#include "bbcreaMaracasVisuPackage.h"
+#include "creaSystem.h"
+
+namespace bbcreaMaracasVisu
+{
+
+BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaMaracasVisu,CutModule2)
+BBTK_BLACK_BOX_IMPLEMENTATION(CutModule2,bbtk::WxBlackBox);
+void CutModule2::Process()
+{
+
+ vtkImageData* img = bbGetInputIn();
+ vtkRenderWindowInteractor* interactor = bbGetInputInteractor();
+ vtkRenderer* render = bbGetInputRenderer();
+
+ if(img != NULL && interactor != NULL && render != NULL && _mainpanel!=NULL){
+
+ if(_currentimage!=img){
+ _currentimage=img;
+ _mainpanel->setImageData(img);
+ }
+
+ _mainpanel->setInteractor(interactor);
+ _mainpanel->setRenderer(render);
+ bbSetOutputOut(_mainpanel->GetResultImage());
+
+ }
+
+}
+void CutModule2::CreateWidget(wxWindow* parent)
+{
+
+ std::string path = crea::System::GetDllAppPath("bbcreaMaracasVisu.dll");
+ _mainpanel = CutModel2MainPanel::getInstance(parent, path);
+
+ bbSetOutputWidget( _mainpanel);
+ Process();
+
+}
+void CutModule2::bbUserSetDefaultValues()
+{
+ _mainpanel = NULL;
+ _currentimage=NULL;
+}
+void CutModule2::bbUserInitializeProcessing()
+{
+ bbSetInputIn(0);
+ bbSetInputInteractor(0);
+ bbSetInputRenderer(0);
+}
+void CutModule2::bbUserFinalizeProcessing()
+{
+
+}
+}
+// EO namespace bbcreaMaracasVisu
+
+
--- /dev/null
+#ifdef _USE_WXWIDGETS_
+#ifndef __bbcreaMaracasVisuCutModule_h_INCLUDED__
+#define __bbcreaMaracasVisuCutModule_h_INCLUDED__
+#include "bbcreaMaracasVisu_EXPORT.h"
+#include "bbtkWxBlackBox.h"
+#include "CutModel2MainPanel.h"
+
+namespace bbcreaMaracasVisu
+{
+
+class bbcreaMaracasVisu_EXPORT CutModule2
+ :
+ public bbtk::WxBlackBox
+{
+
+ BBTK_BLACK_BOX_INTERFACE(CutModule2,bbtk::WxBlackBox);
+ BBTK_DECLARE_INPUT(In,vtkImageData*);
+ BBTK_DECLARE_INPUT(Interactor,vtkRenderWindowInteractor*);
+ BBTK_DECLARE_INPUT(Renderer,vtkRenderer*);
+ BBTK_DECLARE_OUTPUT(Out,vtkImageData*);
+ BBTK_PROCESS(Process);
+ void Process();
+ BBTK_CREATE_WIDGET(CreateWidget);
+ void CreateWidget(wxWindow*);
+
+private:
+ CutModel2MainPanel* _mainpanel;
+ vtkImageData* _currentimage;
+};
+
+BBTK_BEGIN_DESCRIBE_BLACK_BOX(CutModule2,bbtk::WxBlackBox);
+BBTK_NAME("CutModule2");
+BBTK_AUTHOR("perez@creatis.insa-lyon.fr");
+BBTK_DESCRIPTION("extracts");
+BBTK_CATEGORY("__CategoryBlackBox__");
+BBTK_INPUT(CutModule2,In,"Image",vtkImageData*,"");
+BBTK_INPUT(CutModule2,Interactor,"WindowInteractor",vtkRenderWindowInteractor*,"");
+BBTK_INPUT(CutModule2,Renderer,"Renderer",vtkRenderer*,"");
+BBTK_OUTPUT(CutModule2,Out,"Image output",vtkImageData*,"");
+BBTK_END_DESCRIBE_BLACK_BOX(CutModule2);
+}
+// EO namespace bbcreaMaracasVisu
+
+#endif // __bbcreaMaracasVisuCutModule_h_INCLUDED__
+#endif // _USE_WXWIDGETS_
+
//vtkImageData* img1 = ;
- bbSetOutputOut0(volview->GetOutputImages()[0]);
- bbSetOutputOut1(volview->GetOutputImages()[1]);
- bbSetOutputOut2(volview->GetOutputImages()[2]);
- bbSetOutputOut3(volview->GetOutputImages()[3]);
+ //bbSetOutputOut0(volview->GetOutputImages()[0]);
+ //bbSetOutputOut1(volview->GetOutputImages()[1]);
+ //bbSetOutputOut2(volview->GetOutputImages()[2]);
+ //bbSetOutputOut3(volview->GetOutputImages()[3]);
}
}
void VolumeRendering::CreateWidget(wxWindow* parent)