]> Creatis software - creaVtk.git/blob - bbtk_creaVtk_PKG/src/bbcreaVtkTrimmedExtrusionFilter.cxx
#3490 Bug Windows vtkTrimmedExtrusionFilter.h No such file or directory
[creaVtk.git] / bbtk_creaVtk_PKG / src / bbcreaVtkTrimmedExtrusionFilter.cxx
1 //===== 
2 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
3 //=====
4
5 #include "bbcreaVtkTrimmedExtrusionFilter.h"
6
7 #include "bbcreaVtkPackage.h"
8
9
10
11 namespace bbcreaVtk
12 {
13
14 BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaVtk,TrimmedExtrusionFilter)
15 BBTK_BLACK_BOX_IMPLEMENTATION(TrimmedExtrusionFilter,bbtk::AtomicBlackBox);
16 //===== 
17 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
18 //===== 
19 void TrimmedExtrusionFilter::Process()
20 {
21
22 // THE MAIN PROCESSING METHOD BODY
23 //   Here we simply set the input 'In' value to the output 'Out'
24 //   And print out the output value
25 // INPUT/OUTPUT ACCESSORS ARE OF THE FORM :
26 //    void bbSet{Input|Output}NAME(const TYPE&)
27 //    const TYPE& bbGet{Input|Output}NAME() const 
28 //    Where :
29 //    * NAME is the name of the input/output
30 //      (the one provided in the attribute 'name' of the tag 'input')
31 //    * TYPE is the C++ type of the input/output
32 //      (the one provided in the attribute 'type' of the tag 'input')
33 //    bbSetOutputOut( bbGetInputIn() );
34 //    std::cout << "Output value = " <<bbGetOutputOut() << std::endl;
35  
36     
37     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
38     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
39     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
40     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
41     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
42     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
43     printf("EED Warning!!!   TrimmedExtrusionFilter::Process      Box not tested.......  \n");
44
45     
46     
47 /* ------ Not exist in windows  old VTK 8.1 version ---------
48
49     if ( (bbGetInputIn()!=NULL) && (bbGetInputIn2()!=NULL) )
50     {
51         if (extrusion!=NULL)
52         {
53             extrusion->Delete();
54         }
55         extrusion = vtkTrimmedExtrusionFilter::New();
56         std::vector<double> dir=bbGetInputDirection();
57         if (dir.size()==3)
58         {
59             extrusion->SetExtrusionDirection( dir[0],dir[1],dir[2] );
60         } else {
61             extrusion->SetExtrusionDirection( 1,0,0 );
62         }
63         extrusion->SetInputData( bbGetInputIn() );
64         extrusion->SetTrimSurfaceData( bbGetInputIn2() );
65         if (bbGetInputType()==0)
66         {
67             extrusion->SetExtrusionStrategy(vtkTrimmedExtrusionFilter::BOUNDARY_EDGES);
68         } else {
69             extrusion->SetExtrusionStrategy(vtkTrimmedExtrusionFilter::ALL_EDGES);
70         }
71         extrusion->Update();
72         bbSetOutputOut( extrusion->GetTrimSurface() );
73     } else {
74         printf("EED  Warning!!!  TrimmedExtrusionFilter::Process      Either In or In2 is missing \n");
75     } // if bbGetInputIn
76 */
77     
78 }
79 //===== 
80 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
81 //===== 
82 void TrimmedExtrusionFilter::bbUserSetDefaultValues()
83 {
84
85 //  SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX 
86 //    Here we initialize the input 'In' to 0
87
88 // ------ Not exist in windows  old VTK 8.1 version ---------
89 //    extrusion=NULL;
90      
91     bbSetInputIn(NULL);
92     bbSetInputIn2(NULL);
93     bbSetInputType(0);
94
95     std::vector<double> dir;
96     dir.push_back(1);
97     dir.push_back(0);
98     dir.push_back(0);
99     bbSetInputDirection( dir );
100
101 }
102 //===== 
103 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
104 //===== 
105 void TrimmedExtrusionFilter::bbUserInitializeProcessing()
106 {
107
108 //  THE INITIALIZATION METHOD BODY :
109 //    Here does nothing 
110 //    but this is where you should allocate the internal/output pointers 
111 //    if any 
112
113   
114 }
115 //===== 
116 // Before editing this file, make sure it's a file of your own (i.e.: it wasn't generated from xml description; if so : your modifications will be lost)
117 //===== 
118 void TrimmedExtrusionFilter::bbUserFinalizeProcessing()
119 {
120
121 //  THE FINALIZATION METHOD BODY :
122 //    Here does nothing 
123 //    but this is where you should desallocate the internal/output pointers 
124 //    if any
125   
126 }
127
128 } // EO namespace bbcreaVtk
129
130