still used for "selection" nodes
| 511 | |
| 512 | // still used for "selection" nodes |
| 513 | void OcTreeDrawer::generateCubes(const std::list<octomap::OcTreeVolume>& voxels, |
| 514 | GLfloat*** glArray, unsigned int& glArraySize, |
| 515 | octomath::Pose6D& origin, |
| 516 | GLfloat** glColorArray) { |
| 517 | unsigned int i = 0; |
| 518 | unsigned int colorIdx = 0; |
| 519 | |
| 520 | std::vector<octomath::Vector3> cube_template; |
| 521 | initCubeTemplate(origin, cube_template); |
| 522 | |
| 523 | for (std::list<octomap::OcTreeVolume>::const_iterator it=voxels.begin(); |
| 524 | it != voxels.end(); it++) { |
| 525 | i = generateCube(*it, cube_template, i, glArray); |
| 526 | } |
| 527 | |
| 528 | if (glColorArray != NULL) { |
| 529 | for (std::list<octomap::OcTreeVolume>::const_iterator it=voxels.begin(); |
| 530 | it != voxels.end(); it++) { |
| 531 | colorIdx = setCubeColorHeightmap(*it, colorIdx, glColorArray); |
| 532 | } |
| 533 | } |
| 534 | } |
| 535 | |
| 536 | void OcTreeDrawer::initOctreeGridVis() { |
| 537 |