MorphoGraphX  2.0-1-227
CellAtlasPrimordium.hpp
Go to the documentation of this file.
1 #ifndef CELL_ATLAS_PRIMORDIUM_HPP
2 #define CELL_ATLAS_PRIMORDIUM_HPP
3 
4 #include <CellAtlasConfig.hpp>
5 
6 #include <Process.hpp>
7 #include <RootCellAnalyzing.hpp>
8 #include <RootCellProcessing.hpp>
9 #include <CellAtlas.hpp>
10 
11 
12 
13 using namespace std;
14 
15 namespace mgx
16 {
17  static RootCellProcessing rcp;
18 
19  // for attribute maps
21 
22  };
23 
25  {
26  public:
27  AnalyzeLeafPrimSurf(const Process& process) : Process(process)
28  {
29  setName("Mesh/Cell Atlas 3D/Stack/Analyze Leaf Primordium");
30  setDesc("Analyzes the primordium, select vertices on the surface mesh at the side of the origin of the coordinate system");
31  setIcon(QIcon(":/images/CellAtlas.png"));
32  }
33 
34  bool run(){
35  const Stack *s1 = currentStack();//stack(0);
36  if(!checkState().mesh())
37  return false;
38  Mesh *m = currentMesh();
39  if(currentMesh() == mesh(0)){
40  //cout << "s1" << endl;
41  return run(s1, m, rcp.prim1);
42  } else {
43  //cout << "s2" << endl;
44  return run(s1, m, rcp.prim2);
45  }
46 
47  }
48  bool run(const Stack *s1, Mesh *m1, primDataStructure& p);
49 
50  };
51 
52  // run analyzeLeafPrim on mesh1 and mesh2 first
53  // then project stack1 onto stack2 (which will be generated in the process)
55  {
56  public:
57  ProjectLeafPrimStack(const Process& process) : Process(process)
58  {
59  setName("Mesh/Cell Atlas 3D/Stack/Project Leaf Prim Stack");
60  setDesc("Analyzes the primordium");
61  setIcon(QIcon(":/images/CellAtlas.png"));
62 
63  addParm("Quality","Quality","500");
64  }
65 
66  bool run(){
67 
68  Stack* s1 = stack(0);
69  Stack* s2 = stack(1);
70  Store* input = s1->currentStore();
71  //Store* output = s2->currentStore();
72  Store* output = s2->work();
73 
74  primDataStructure &p1 = rcp.prim1;
75  primDataStructure &p2 = rcp.prim2;
76 
77  return run(s1, s2, input, output, p1, p2, parm("Quality").toInt());
78  }
79 
80  bool run(Stack* s1, Stack* s2, Store* input, Store* output, primDataStructure &cellData1, primDataStructure &cellData2, int threshold);
81 
82  };
83 
85  {
86  public:
87  CellAtlasStack(const Process& process) : Process(process)
88  {
89  setName("Mesh/Cell Atlas 3D/Stack/Longitudinal Signal Histogram");
90  setDesc("TBD");
91  setIcon(QIcon(":/images/MakeHeatMap.png"));
92 
93  addParm("Bin Size","Bin Size","1.0");
94  addParm("Rad Min","Rad Min","0.0");
95  addParm("Rad Max","Rad Max","1.0");
96  addParm("Rad Type","Rad Type","absolute");
97  addParm("Save to File","Save to File","");
98  addParm("Voxel Cube Size","Voxel Cube Size","1");
99  }
100 
101  bool processParms();
102 
103  bool run()
104  {
105  Stack* s1 = currentStack();
106  Store* store1 = s1->main();
107  Store* store2 = s1->work();
108  Mesh* m = currentMesh();
109  return run(s1, store1, store2, m, parm("Bin Size").toDouble(), parm("Rad Min").toDouble(), parm("Rad Max").toDouble(), parm("Rad Type"), parm("Save to File"), parm("Voxel Cube Size").toInt());
110  }
111 
112  bool run(Stack* s1, Store* store1, Store* store2, Mesh* m, double binSize, double radMin, double radMax, QString radType, QString filename, int cubeSize);
113 
114  };
115 
116 
117 }
118 
119 #endif
mgx::AnalyzeLeafPrimSurf::AnalyzeLeafPrimSurf
AnalyzeLeafPrimSurf(const Process &process)
Definition: CellAtlasPrimordium.hpp:27
Process.hpp
mgx::RootCellProcessing::prim2
primDataStructure prim2
Definition: RootCellProcessing.hpp:531
mgx::Stack::work
const Store * work() const
Access the work store.
Definition: Stack.hpp:101
mgx::Stack::currentStore
const Store * currentStore() const
Returns the current store.
Definition: Stack.hpp:120
mgx::Stack::main
const Store * main() const
Access the main store.
Definition: Stack.hpp:82
CellAtlas.hpp
mgx::CellAtlasStack
Definition: CellAtlasPrimordium.hpp:84
mgx::Stack
Definition: Stack.hpp:33
RootCellProcessing.hpp
mgx
Distributed matrix library.
Definition: Assert.hpp:26
mgx::primDataStructure
Definition: RootCellProcessing.hpp:27
mgx::CellAtlasStack::run
bool run()
Runs the process.
Definition: CellAtlasPrimordium.hpp:103
RootCellAnalyzing.hpp
CellAtlas_EXPORT
#define CellAtlas_EXPORT
Definition: CellAtlasConfig.hpp:26
mgx::Process
Definition: Process.hpp:219
mgx::AnalyzeLeafPrimSurf
Definition: CellAtlasPrimordium.hpp:24
mgx::Mesh
Definition: Mesh.hpp:54
mgx::CellAtlasStack::CellAtlasStack
CellAtlasStack(const Process &process)
Definition: CellAtlasPrimordium.hpp:87
mgx::CellAtlasPrimordiumData
Definition: CellAtlasPrimordium.hpp:20
CellAtlasConfig.hpp
mgx::ProjectLeafPrimStack::ProjectLeafPrimStack
ProjectLeafPrimStack(const Process &process)
Definition: CellAtlasPrimordium.hpp:57
mgx::AnalyzeLeafPrimSurf::run
bool run()
Runs the process.
Definition: CellAtlasPrimordium.hpp:34
mgx::ProjectLeafPrimStack
Definition: CellAtlasPrimordium.hpp:54
mgx::ProjectLeafPrimStack::run
bool run()
Runs the process.
Definition: CellAtlasPrimordium.hpp:66
mgx::Store
Definition: Store.hpp:33
mgx::RootCellProcessing::prim1
primDataStructure prim1
Definition: RootCellProcessing.hpp:531