]> Creatis software - creaVtk.git/blob - bbtk_creaVtk_PKG/src/bbcreaVtkMeshManager.cxx
cb4cca82146eacf3fbfeb8ca1810acf8ce9c1679
[creaVtk.git] / bbtk_creaVtk_PKG / src / bbcreaVtkMeshManager.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 #include "bbcreaVtkMeshManager.h"
5 #include "bbcreaVtkPackage.h"
6 namespace bbcreaVtk
7 {
8
9 BBTK_ADD_BLACK_BOX_TO_PACKAGE(creaVtk,MeshManager)
10 BBTK_BLACK_BOX_IMPLEMENTATION(MeshManager,bbtk::AtomicBlackBox);
11 //===== 
12 // 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)
13 //===== 
14 void MeshManager::Process()
15 {
16 // THE MAIN PROCESSING METHOD BODY
17 //   Here we simply set the input 'In' value to the output 'Out'
18 //   And print out the output value
19 // INPUT/OUTPUT ACCESSORS ARE OF THE FORM :
20 //    void bbSet{Input|Output}NAME(const TYPE&)
21 //    const TYPE& bbGet{Input|Output}NAME() const 
22 //    Where :
23 //    * NAME is the name of the input/output
24 //      (the one provided in the attribute 'name' of the tag 'input')
25 //    * TYPE is the C++ type of the input/output
26 //      (the one provided in the attribute 'type' of the tag 'input')
27 //    bbSetOutputOut( bbGetInputIn() );
28 //    std::cout << "Output value = " <<bbGetOutputOut() << std::endl;
29     if (meshManagerModel==NULL)
30     {
31         meshManagerModel = new MeshManagerModel();
32         meshManagerModel->SetMeshBase( bbGetInputMesh() );
33         bbSetOutputMeshBase( meshManagerModel->GetMeshBase() );
34         bbSetOutputMeshTemp( meshManagerModel->GetMeshTemp() );
35         bbSetOutputMeshManagerModel( meshManagerModel );
36     }
37 }
38
39 //===== 
40 // 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)
41 //===== 
42 void MeshManager::bbUserSetDefaultValues()
43 {
44 //  SET HERE THE DEFAULT INPUT/OUTPUT VALUES OF YOUR BOX 
45 //    Here we initialize the input 'In' to 0
46 //   bbSetInputIn(0);
47     meshManagerModel = NULL;
48     bbSetInputMesh(NULL);
49 }
50
51 //===== 
52 // 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)
53 //===== 
54 void MeshManager::bbUserInitializeProcessing()
55 {
56 //  THE INITIALIZATION METHOD BODY :
57 //    Here does nothing 
58 //    but this is where you should allocate the internal/output pointers 
59 //    if any
60 }
61
62 //===== 
63 // 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)
64 //===== 
65 void MeshManager::bbUserFinalizeProcessing()
66 {
67 //  THE FINALIZATION METHOD BODY :
68 //    Here does nothing 
69 //    but this is where you should desallocate the internal/output pointers 
70 //    if any
71 }
72
73 } // EO namespace bbcreaVtk
74
75