1 /*# ---------------------------------------------------------------------
3 # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image
5 # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton
6 # Previous Authors : Laurent Guigues, Jean-Pierre Roux
7 # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil
9 # This software is governed by the CeCILL-B license under French law and
10 # abiding by the rules of distribution of free software. You can use,
11 # modify and/ or redistribute the software under the terms of the CeCILL-B
12 # license as circulated by CEA, CNRS and INRIA at the following URL
13 # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
14 # or in the file LICENSE.txt.
16 # As a counterpart to the access to the source code and rights to copy,
17 # modify and redistribute granted by the license, users are provided only
18 # with a limited warranty and the software's author, the holder of the
19 # economic rights, and the successive licensors have only limited
22 # The fact that you are presently reading this means that you have had
23 # knowledge of the CeCILL-B license and that you accept its terms.
24 # ------------------------------------------------------------------------ */
26 #include "bbcreaMaracasVisuSurfaceRendering.h"
27 #include "bbcreaMaracasVisuPackage.h"
30 #include "wxMaracasSurfaceRendering.h"
32 namespace bbcreaMaracasVisu
35 BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaMaracasVisu,SurfaceRendering)
36 BBTK_BLACK_BOX_IMPLEMENTATION(SurfaceRendering,bbtk::WxBlackBox);
37 void SurfaceRendering::Process()
40 wxMaracasSurfaceRendering* surrend = wxMaracasSurfaceRendering::getInstance();
41 std::vector<vtkImageData*> tempvect;
45 vtkRenderer* renderer = bbGetInputRenderer();
46 vtkRenderWindowInteractor* interactor = bbGetInputInteractor();
47 surrend->setRenderer(renderer);
48 surrend->setInteractor(interactor);
50 tempvect.push_back(bbGetInputIn0());
51 tempvect.push_back(bbGetInputIn1());
52 tempvect.push_back(bbGetInputIn2());
53 tempvect.push_back(bbGetInputIn3());
54 tempvect.push_back(bbGetInputIn4());
56 for(i = 0; i < (int)tempvect.size();i++){
58 if(prop3D != NULL&&renderer != NULL){
59 surrend->addPropMHD(prop3D);
64 void SurfaceRendering::CreateWidget(wxWindow* parent)
68 //std::cout << "Your application's directory is: " << path;
70 wxMaracasSurfaceRendering* surrend = wxMaracasSurfaceRendering::getInstance(parent);
71 //GetDllDirectory(_MAX_PATH, currentPath);
72 //std::cout << "Your application's directory is: " << GetDllDirectory(_MAX_PATH, currentPath)<<std::endl;
74 bbSetOutputWidget(surrend);
78 //-----------------------------------------------------------------
79 void SurfaceRendering::bbUserSetDefaultValues()
86 bbSetInputRenderer(NULL);
87 bbSetInputInteractor(NULL);
88 bbSetOutputWidget(NULL);
89 bbSetOutputOut1(NULL);
90 bbSetOutputOut2(NULL);
91 bbSetOutputOut3(NULL);
92 bbSetOutputOut4(NULL);
95 //-----------------------------------------------------------------
96 void SurfaceRendering::bbUserInitializeProcessing()
100 //-----------------------------------------------------------------
101 void SurfaceRendering::bbUserFinalizeProcessing()
105 //-----------------------------------------------------------------
110 // EO namespace bbcreaMaracasVisu