62 #include "DGtal/base/Common.h"
63 #include "DGtal/helpers/StdDefs.h"
64 #include "DGtal/io/viewers/Viewer3D.h"
69 using namespace DGtal;
79 std::map< DGtal::int32_t, Z3i::SCell > cells;
84 std::map< DGtal::int32_t, Z3i::Point > voxels;
89 BigDataCells* bg = (BigDataCells*) data;
90 stringstream ssMessage;
91 ssMessage <<
"Reaction1 with name " << name <<
" cell " << bg->K.sKCoords( bg->cells[ name ] ) ;
92 ((
MyViewer *) viewer)->displayMessage(QString(ssMessage.str().c_str()), 100000);
93 trace.
info() << ssMessage.str() << std::endl;
98 BigDataCells* bg = (BigDataCells*) data;
99 stringstream ssMessage;
100 ssMessage <<
"Reaction23 with name " << name <<
" cell " << bg->K.sKCoords( bg->cells[ name ] );
101 ((
MyViewer *) viewer)->displayMessage(QString(ssMessage.str().c_str()), 100000);
102 trace.
info() << ssMessage.str() << std::endl;
107 BigDataVoxels* bg = (BigDataVoxels*) data;
108 stringstream ssMessage;
109 ssMessage <<
"Reaction4 with name " << name <<
" Voxel " << bg->voxels[name] ;
110 ((
MyViewer *) viewer)->displayMessage(QString(ssMessage.str().c_str()), 100000);
111 trace.
info() << ssMessage.str() << std::endl;
117 int main(
int argc,
char** argv )
119 QApplication application(argc,argv);
126 K.
init( p1, p2,
true );
131 dataV.voxels[4001] = v1;
132 dataV.voxels[4002] = v2;
133 dataV.voxels[4003] = v3;
138 viewer.displayMessage(QString(
"You can use [shift + click right] on surfels or voxel to interact ..."), 100000);
142 data.cells[ 10001 ] = surfel1;
143 data.cells[ 10002 ] = surfel2;
144 data.cells[ 10003 ] = surfel3;
157 viewer<< MyViewer::updateDisplay;
158 return application.exec();
Aim: This class is a model of CCellularGridSpaceND. It represents the cubical grid as a cell complex,...
bool init(const Point &lower, const Point &upper, bool isClosed)
Specifies the upper and lower bounds for the maximal cells in this space.
SCell sCell(const SPreCell &c) const
From a signed cell, returns a signed cell lying into this Khalismky space.
Display::SelectCallbackFct SelectCallbackFct
DGtal is the top-level namespace which contains all DGtal functions and types.
boost::int32_t int32_t
signed 32-bit integer.
Modifier class in a Display3D stream. Useful to choose your own mode for a given class....
Represents a signed cell in a cellular grid space by its Khalimsky coordinates and a boolean value.
std::string className() const
Return the style name used for drawing this object.
int main(int argc, char **argv)