| 245 | } |
| 246 | |
| 247 | size_t |
| 248 | TrackerObject::appendToPointCloud(pcl::PointCloud<pcl::PointXYZRGB>::Ptr& pointcloud, size_t starting_index, size_t max_size) |
| 249 | { |
| 250 | for(size_t i = 0; i < tracks_.size() && pointcloud->size() < max_size; i++) |
| 251 | { |
| 252 | pcl::PointXYZRGB point; |
| 253 | pointcloud->push_back(point); |
| 254 | } |
| 255 | |
| 256 | for(std::list<open_ptrack::tracking::TrackObject*>::iterator it = tracks_.begin(); it != tracks_.end(); it++) |
| 257 | { |
| 258 | open_ptrack::tracking::TrackObject* t = *it; |
| 259 | if(t->getPointXYZRGB(pointcloud->points[starting_index])) |
| 260 | starting_index = (starting_index + 1) % max_size; |
| 261 | |
| 262 | } |
| 263 | return starting_index; |
| 264 | } |
| 265 | |
| 266 | /************************ protected methods ************************/ |
| 267 |
nothing calls this directly
no test coverage detected