| 222 | } |
| 223 | |
| 224 | size_t |
| 225 | Tracker3D::appendToPointCloud(pcl::PointCloud<pcl::PointXYZRGB>::Ptr& pointcloud, size_t starting_index, size_t max_size) |
| 226 | { |
| 227 | for(size_t i = 0; i < tracks_.size() && pointcloud->size() < max_size; i++) |
| 228 | { |
| 229 | pcl::PointXYZRGB point; |
| 230 | pointcloud->push_back(point); |
| 231 | } |
| 232 | |
| 233 | for(std::list<open_ptrack::tracking::Track3D*>::iterator it = tracks_.begin(); it != tracks_.end(); it++) |
| 234 | { |
| 235 | open_ptrack::tracking::Track3D* t = *it; |
| 236 | if(t->getPointXYZRGB(pointcloud->points[starting_index])) |
| 237 | starting_index = (starting_index + 1) % max_size; |
| 238 | |
| 239 | } |
| 240 | return starting_index; |
| 241 | } |
| 242 | |
| 243 | /************************ protected methods ************************/ |
| 244 |
nothing calls this directly
no test coverage detected