37 #include <GLUT/glut.h>
47 using namespace GMap3d;
70 int markVoxel = G->getNewMark();
72 CDynamicCoverageAll Cgm(G);
73 for (Cgm.reinit(); Cgm.cont(); Cgm++)
78 if (!G->isMarked(d, markVoxel))
183 CCoverage* DC = G->getDynamicCoverage(d, ORBIT_0123);
184 for (DC->reinit(); DC->cont(); (*DC) ++)
185 G->setMark(**DC, markVoxel);
189 for (Cgm.reinit(); Cgm.cont(); Cgm++)
190 G->unsetMark(*Cgm, markVoxel);
193 G->freeMark(markVoxel);
207 int markVoxel = G->getNewMark();
209 CDynamicCoverageAll Cgm(G);
210 for (Cgm.reinit(); Cgm.cont(); Cgm++)
215 if (!G->isMarked(d, markVoxel))
235 CCoverage* DC = G->getDynamicCoverage(d, ORBIT_0123);
236 for (DC->reinit(); DC->cont(); (*DC)++)
237 G->setMark(**DC, markVoxel);
241 for (Cgm.reinit(); Cgm.cont(); Cgm++)
242 G->unsetMark(*Cgm, markVoxel);
245 G->freeMark(markVoxel);
259 int markVoxel = G->getNewMark();
261 CDynamicCoverageAll Cgm(G);
262 for (Cgm.reinit(); Cgm.cont(); Cgm++)
267 if (!G->isMarked(d, markVoxel))
287 glVertex3f(i+1, j, k);
293 glVertex3f(i, j+1, k);
299 glVertex3f(i, j, k+1);
305 CCoverage* DC = G->getDynamicCoverage(d, ORBIT_0123);
306 for (DC->reinit(); DC->cont(); (*DC)++)
307 G->setMark(**DC, markVoxel);
311 for (Cgm.reinit(); Cgm.cont(); Cgm++)
312 G->unsetMark(*Cgm, markVoxel);
315 G->freeMark(markVoxel);
329 int markVoxel = G->getNewMark();
332 glEnable(GL_LIGHTING);
333 glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_TRUE);
335 CDynamicCoverageAll Cgm(G);
336 for (Cgm.reinit(); Cgm.cont(); Cgm++)
341 if (!G->isMarked(d, markVoxel))
359 glNormal3f(0.0, 0.0, 1.0);
360 glVertex3f(i+0.2, j+0.2, k);
361 glVertex3f(i+0.8, j+0.2, k);
362 glVertex3f(i+0.8, j+0.8, k);
363 glVertex3f(i+0.2, j+0.8, k);
367 glNormal3f(1.0, 0.0, 0.0);
368 glVertex3f(i, j+0.2, k+0.2);
369 glVertex3f(i, j+0.8, k+0.2);
370 glVertex3f(i, j+0.8, k+0.8);
371 glVertex3f(i, j+0.2, k+0.8);
375 glNormal3f(0.0, 1.0, 0.0);
376 glVertex3f(i+0.2, j, k+0.2);
377 glVertex3f(i+0.2, j, k+0.8);
378 glVertex3f(i+0.8, j, k+0.8);
379 glVertex3f(i+0.8, j, k+0.2);
383 CCoverage* DC = G->getDynamicCoverage(d, ORBIT_0123);
384 for (DC->reinit(); DC->cont(); (*DC)++)
385 G->setMark(**DC, markVoxel);
389 for (Cgm.reinit(); Cgm.cont(); Cgm++)
390 G->unsetMark(*Cgm, markVoxel);
393 G->freeMark(markVoxel);
396 glDisable(GL_LIGHTING);
397 glLightModeli(GL_LIGHT_MODEL_TWO_SIDE, GL_FALSE);