42 ConnectionBasedNodelet::onInit();
44 "output_polygons", 1);
46 = advertise<jsk_recognition_msgs::ModelCoefficientsArray>(*pnh_,
47 "output_coefficients", 1);
64 sync_ = boost::make_shared<message_filters::Synchronizer<SyncPolicy> >(100);
68 sync_->registerCallback(boost::bind(
80 const geometry_msgs::PolygonStamped::ConstPtr& polygon,
81 const pcl_msgs::ModelCoefficients::ConstPtr& coefficients)
83 jsk_recognition_msgs::PolygonArray array_msg;
84 array_msg.header = polygon->header;
85 geometry_msgs::PolygonStamped new_polygon(*polygon);
86 array_msg.polygons.push_back(new_polygon);
89 jsk_recognition_msgs::ModelCoefficientsArray coefficients_array;
91 pcl_msgs::ModelCoefficients new_coefficients(*coefficients);
92 coefficients_array.coefficients.push_back(new_coefficients);