Changes have been pushed for the project "Fawkes Robotics Software Framework".
Gitweb: http://git.fawkesrobotics.org/fawkes.git Trac: http://trac.fawkesrobotics.org The branch, thofmann/tabletop-obj-refactor has been updated to 5f8b2a30f041d2dcea5729a6ffd51dc498bdeff3 (commit) via 8409a40fd560e8eda6ac9ffd14b5e89bcb24a6fd (commit) from 81067a337d87d7c12b688540d64fce0afee7a777 (commit) http://git.fawkesrobotics.org/fawkes.git/thofmann/tabletop-obj-refactor Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - *Log* --------------------------------------------------------------- commit 8409a40fd560e8eda6ac9ffd14b5e89bcb24a6fd Author: Till Hofmann <hofm...@kbsg.rwth-aachen.de> AuthorDate: Tue Apr 30 19:24:26 2013 +0200 Commit: Till Hofmann <hofm...@kbsg.rwth-aachen.de> CommitDate: Tue Apr 30 19:33:59 2013 +0200 tabletop-objects: remove unused method (overloaded colorize_cluster) colorize_cluster always colorizes only a part of the cloud, we don't need it to be able to colorize a complete cloud, therefore remove overloaded method. http://git.fawkesrobotics.org/fawkes.git/commit/8409a40 http://trac.fawkesrobotics.org/changeset/8409a40 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - commit 5f8b2a30f041d2dcea5729a6ffd51dc498bdeff3 Author: Till Hofmann <hofm...@kbsg.rwth-aachen.de> AuthorDate: Tue Apr 30 19:27:29 2013 +0200 Commit: Till Hofmann <hofm...@kbsg.rwth-aachen.de> CommitDate: Tue Apr 30 19:34:10 2013 +0200 tabletop-objects: fix bug in colorizing table cluster The table cluster's points are the first n in temp_cloud2 where n is the size of inliers->indices. inliers->indices does not index the table's points. http://git.fawkesrobotics.org/fawkes.git/commit/5f8b2a3 http://trac.fawkesrobotics.org/changeset/5f8b2a3 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - *Summary* ----------------------------------------------------------- .../tabletop-objects/tabletop_objects_thread.cpp | 20 ++++++++------------ .../tabletop-objects/tabletop_objects_thread.h | 2 -- 2 files changed, 8 insertions(+), 14 deletions(-) - *Diffs* ------------------------------------------------------------- - *commit* 8409a40fd560e8eda6ac9ffd14b5e89bcb24a6fd - - - - - - - - - - Author: Till Hofmann <hofm...@kbsg.rwth-aachen.de> Date: Tue Apr 30 19:24:26 2013 +0200 Subject: tabletop-objects: remove unused method (overloaded colorize_cluster) .../tabletop-objects/tabletop_objects_thread.cpp | 15 ++++----------- .../tabletop-objects/tabletop_objects_thread.h | 2 -- 2 files changed, 4 insertions(+), 13 deletions(-) _Diff for modified files_: diff --git a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp index 4b3cc79..dc4597c 100644 --- a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp +++ b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp @@ -1096,19 +1096,12 @@ TabletopObjectsThread::ColorCloudPtr TabletopObjectsThread::colorize_cluster ( CloudConstPtr input_cloud, const std::vector<int> &cluster, const uint8_t color[]) { - return colorize_cluster(CloudConstPtr(new Cloud(*input_cloud, cluster)), color); -} - -TabletopObjectsThread::ColorCloudPtr TabletopObjectsThread::colorize_cluster( - CloudConstPtr input_cloud, - const uint8_t color[]) { ColorCloudPtr result(new ColorCloud()); - result->resize(input_cloud->size()); - Cloud::const_iterator pit; + result->resize(cluster.size()); uint i = 0; - for (pit = input_cloud->begin(); pit != input_cloud->end(); ++pit, ++i) { - ColorPointType &p1 = result->points[i]; - const PointType &p2 = *pit; + for (std::vector<int>::const_iterator it = cluster.begin(); it != cluster.end(); ++it, ++i) { + ColorPointType &p1 = result->points.at(i); + const PointType &p2 = input_cloud->points.at(*it); p1.x = p2.x; p1.y = p2.y; p1.z = p2.z; diff --git a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.h b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.h index 543504c..c289186 100644 --- a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.h +++ b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.h @@ -102,8 +102,6 @@ class TabletopObjectsThread ColorCloudPtr colorize_cluster(CloudConstPtr input_cloud, const std::vector<int> &cluster, const uint8_t color[]); - ColorCloudPtr colorize_cluster(CloudConstPtr input_cloud, const uint8_t color[]); - unsigned int add_objects(CloudConstPtr input, ColorCloudPtr tmp_clusters); void reset_obj_ids(); - *commit* 5f8b2a30f041d2dcea5729a6ffd51dc498bdeff3 - - - - - - - - - - Author: Till Hofmann <hofm...@kbsg.rwth-aachen.de> Date: Tue Apr 30 19:27:29 2013 +0200 Subject: tabletop-objects: fix bug in colorizing table cluster .../tabletop-objects/tabletop_objects_thread.cpp | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) _Diff for modified files_: diff --git a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp index dc4597c..e205c70 100644 --- a/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp +++ b/src/plugins/perception/tabletop-objects/tabletop_objects_thread.cpp @@ -956,7 +956,10 @@ TabletopObjectsThread::loop() TIMETRACK_INTER(ttc_polygon_filter_, ttc_table_to_output_) - ColorCloudPtr tmp_clusters = colorize_cluster(temp_cloud2, inliers->indices, table_color); + std::vector<int> indices(inliers->indices); + for (uint i = 0; i < indices.size(); i++) + indices[i] = i; + ColorCloudPtr tmp_clusters = colorize_cluster(temp_cloud2, indices, table_color); TIMETRACK_INTER(ttc_table_to_output_, ttc_cluster_objects_) -- Fawkes Robotics Framework http://www.fawkesrobotics.org _______________________________________________ fawkes-commits mailing list fawkes-commits@lists.kbsg.rwth-aachen.de https://lists.kbsg.rwth-aachen.de/listinfo/fawkes-commits