Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate boost::function to std::function #3079

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,11 @@
#include <pcl/io/io.h>
#include <pcl/io/pcd_io.h>
#include <pcl/apps/3d_rec_framework/utils/vtk_model_sampling.h>
#include <boost/function.hpp>

#include <vtkTransformPolyDataFilter.h>

#include <functional>

namespace pcl
{
namespace rec_3d_framework
Expand Down Expand Up @@ -42,7 +44,7 @@ namespace pcl
float radius_sphere_;
float view_angle_;
bool gen_organized_;
boost::function<bool
std::function<bool
(const Eigen::Vector3f &)> campos_constraints_func_;

public:
Expand All @@ -62,7 +64,7 @@ namespace pcl
}

void
setCamPosConstraints (boost::function<bool
setCamPosConstraints (std::function<bool
(const Eigen::Vector3f &)> & bb)
{
campos_constraints_func_ = bb;
Expand Down
2 changes: 1 addition & 1 deletion apps/3d_rec_framework/src/tools/global_classification.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ segmentAndClassify (typename pcl::rec_3d_framework::GlobalNNPipeline<DistT, Poin
pcl::visualization::PCLVisualizer vis ("kinect");

//keyboard callback to stop getting frames and finalize application
boost::function<void
std::function<void
(const pcl::visualization::KeyboardEvent&)> keyboard_cb = boost::bind (&OpenNIFrameSource::OpenNIFrameSource::onKeyboardEvent, &camera, _1);
vis.registerKeyboardCallback (keyboard_cb);
size_t previous_cluster_size = 0;
Expand Down
2 changes: 1 addition & 1 deletion apps/3d_rec_framework/src/tools/openni_frame_source.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace OpenNIFrameSource
OpenNIFrameSource::OpenNIFrameSource (const std::string& device_id) :
grabber_ (device_id), frame_counter_ (0), active_ (true)
{
boost::function<void
std::function<void
(const PointCloudConstPtr&)> frame_cb = boost::bind (&OpenNIFrameSource::onNewFrame, this, _1);
grabber_.registerCallback (frame_cb);
grabber_.start ();
Expand Down
2 changes: 1 addition & 1 deletion apps/in_hand_scanner/src/in_hand_scanner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -481,7 +481,7 @@ pcl::ihs::InHandScanner::startGrabberImpl ()
lock.lock ();
if (destructor_called_) return;

boost::function <void (const CloudXYZRGBAConstPtr&)> new_data_cb = boost::bind (&pcl::ihs::InHandScanner::newDataCallback, this, _1);
std::function <void (const CloudXYZRGBAConstPtr&)> new_data_cb = boost::bind (&pcl::ihs::InHandScanner::newDataCallback, this, _1);
new_data_connection_ = grabber_->registerCallback (new_data_cb);
grabber_->start ();

Expand Down
10 changes: 6 additions & 4 deletions apps/include/pcl/apps/render_views_tesselated_sphere.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,12 @@

#pragma once

#include <pcl/common/common.h>

#include <vtkSmartPointer.h>
#include <vtkPolyData.h>
#include <pcl/common/common.h>
#include <boost/function.hpp>

#include <functional>

namespace pcl
{
Expand All @@ -37,7 +39,7 @@ namespace pcl
bool compute_entropy_;
vtkSmartPointer<vtkPolyData> polydata_;
bool gen_organized_;
boost::function<bool
std::function<bool
(const Eigen::Vector3f &)> campos_constraints_func_;

struct camPosConstraintsAllTrue
Expand All @@ -64,7 +66,7 @@ namespace pcl
}

void
setCamPosConstraints (boost::function<bool (const Eigen::Vector3f &)> & bb)
setCamPosConstraints (std::function<bool (const Eigen::Vector3f &)> & bb)
{
campos_constraints_func_ = bb;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,15 +40,17 @@

#pragma once

#include <QGLWidget>
#include <boost/function.hpp>
#include <pcl/apps/point_cloud_editor/localTypes.h>
#include <pcl/apps/point_cloud_editor/common.h>
#include <pcl/apps/point_cloud_editor/commandQueue.h>
#include <pcl/apps/point_cloud_editor/denoiseParameterForm.h>
#include <pcl/apps/point_cloud_editor/statisticsDialog.h>
#include <pcl/apps/point_cloud_editor/toolInterface.h>

#include <QGLWidget>

#include <functional>

/// @brief class declaration for the widget for editing and viewing
/// point clouds.
class CloudEditorWidget : public QGLWidget
Expand Down Expand Up @@ -251,7 +253,7 @@ class CloudEditorWidget : public QGLWidget
return lhs.compare(rhs) < 0;
}
};
typedef boost::function<void (CloudEditorWidget*, const std::string&)>
typedef std::function<void (CloudEditorWidget*, const std::string&)>
FileLoadFunc;
typedef std::map<std::string, FileLoadFunc, ExtCompare> FileLoadMap;
/// a map of file type extensions to loader functions.
Expand Down Expand Up @@ -301,7 +303,7 @@ class CloudEditorWidget : public QGLWidget
/// A flag indicates whether the cloud is initially colored or not.
bool is_colored_;

typedef boost::function<void (CloudEditorWidget*)> KeyMapFunc;
typedef std::function<void (CloudEditorWidget*)> KeyMapFunc;
/// map between pressed key and the corresponding functor
std::map<int, KeyMapFunc> key_map_;

Expand Down
2 changes: 1 addition & 1 deletion apps/src/dinast_grabber_example.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ class DinastProcessor
run ()
{

boost::function<void (const CloudConstPtr&)> f =
std::function<void (const CloudConstPtr&)> f =
boost::bind (&DinastProcessor::cloud_cb_, this, _1);

boost::signals2::connection c = interface.registerCallback (f);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/face_detection/openni_face_detection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ void run(pcl::RFFaceDetectorTrainer & fdrf, bool heat_map = false, bool show_vot
vis.addCoordinateSystem (0.1, "global");

//keyboard callback to stop getting frames and finalize application
boost::function<void(const pcl::visualization::KeyboardEvent&)> keyboard_cb = boost::bind (&OpenNIFrameSource::OpenNIFrameSource::onKeyboardEvent, &camera,
std::function<void(const pcl::visualization::KeyboardEvent&)> keyboard_cb = boost::bind (&OpenNIFrameSource::OpenNIFrameSource::onKeyboardEvent, &camera,
_1);
vis.registerKeyboardCallback (keyboard_cb);

Expand Down
2 changes: 1 addition & 1 deletion apps/src/face_detection/openni_frame_source.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace OpenNIFrameSource
OpenNIFrameSource::OpenNIFrameSource(const std::string& device_id) :
grabber_ (device_id), frame_counter_ (0), active_ (true)
{
boost::function<void(const PointCloudConstPtr&)> frame_cb = boost::bind (&OpenNIFrameSource::onNewFrame, this, _1);
std::function<void(const PointCloudConstPtr&)> frame_cb = boost::bind (&OpenNIFrameSource::onNewFrame, this, _1);
grabber_.registerCallback (frame_cb);
grabber_.start ();
}
Expand Down
2 changes: 1 addition & 1 deletion apps/src/ni_agast.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ class AGASTDemo
void
init ()
{
boost::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&AGASTDemo::cloud_callback, this, _1);
std::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&AGASTDemo::cloud_callback, this, _1);
cloud_connection = grabber_.registerCallback (cloud_cb);
}

Expand Down
2 changes: 1 addition & 1 deletion apps/src/ni_brisk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ class BRISKDemo
void
init ()
{
boost::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&BRISKDemo::cloud_callback, this, _1);
std::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&BRISKDemo::cloud_callback, this, _1);
cloud_connection = grabber_.registerCallback (cloud_cb);
}

Expand Down
2 changes: 1 addition & 1 deletion apps/src/ni_linemod.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -473,7 +473,7 @@ class NILinemod
cloud_viewer_.registerMouseCallback (&NILinemod::mouse_callback, *this);
cloud_viewer_.registerKeyboardCallback(&NILinemod::keyboard_callback, *this);
cloud_viewer_.registerPointPickingCallback (&NILinemod::pp_callback, *this);
boost::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&NILinemod::cloud_callback, this, _1);
std::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&NILinemod::cloud_callback, this, _1);
cloud_connection = grabber_.registerCallback (cloud_cb);

image_viewer_.registerMouseCallback (&NILinemod::mouse_callback, *this);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/ni_susan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ class SUSANDemo
void
init ()
{
boost::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&SUSANDemo::cloud_callback, this, _1);
std::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&SUSANDemo::cloud_callback, this, _1);
cloud_connection = grabber_.registerCallback (cloud_cb);
}

Expand Down
2 changes: 1 addition & 1 deletion apps/src/ni_trajkovic.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ class TrajkovicDemo
void
init ()
{
boost::function<void (const CloudConstPtr&) > cloud_cb;
std::function<void (const CloudConstPtr&) > cloud_cb;
if (enable_3d_)
cloud_cb = boost::bind (&TrajkovicDemo::cloud_callback_3d, this, _1);
else
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_3d_concave_hull.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ class OpenNI3DConcaveHull
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNI3DConcaveHull::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNI3DConcaveHull::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.runOnVisualizationThread (boost::bind(&OpenNI3DConcaveHull::viz_cb, this, _1), "viz_cb");
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_3d_convex_hull.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ class OpenNI3DConvexHull
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNI3DConvexHull::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNI3DConvexHull::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.runOnVisualizationThread (boost::bind(&OpenNI3DConvexHull::viz_cb, this, _1), "viz_cb");
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_boundary_estimation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ class OpenNIIntegralImageNormalEstimation
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr &)> f = boost::bind (&OpenNIIntegralImageNormalEstimation::cloud_cb, this, _1);
std::function<void (const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr &)> f = boost::bind (&OpenNIIntegralImageNormalEstimation::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.runOnVisualizationThread (boost::bind(&OpenNIIntegralImageNormalEstimation::viz_cb, this, _1), "viz_cb");
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_change_viewer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ class OpenNIChangeViewer
{
pcl::Grabber* interface = new pcl::OpenNIGrabber();

boost::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
std::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
boost::bind (&OpenNIChangeViewer::cloud_cb_, this, _1);

boost::signals2::connection c = interface->registerCallback (f);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_color_filter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ class OpenNIPassthrough
: viewer ("PCL OpenNI ColorFilter Viewer")
, grabber_(grabber)
{
boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIPassthrough::cloud_cb_, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIPassthrough::cloud_cb_, this, _1);
boost::signals2::connection c = grabber_.registerCallback (f);

std::vector<bool> lookup(1<<24, false);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_fast_mesh.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ class OpenNIFastMesh
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIFastMesh::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIFastMesh::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

view.reset (new pcl::visualization::PCLVisualizer (argc, argv, "PCL OpenNI Mesh Viewer"));
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_feature_persistence.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ class OpenNIFeaturePersistence
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIFeaturePersistence::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIFeaturePersistence::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.runOnVisualizationThread (boost::bind(&OpenNIFeaturePersistence::viz_cb, this, _1), "viz_cb");
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_grab_frame.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ class OpenNIGrabFrame


// make callback function from member function
boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIGrabFrame::cloud_cb_, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIGrabFrame::cloud_cb_, this, _1);

// connect callback function for desired signal. In this case its a point cloud with color values
boost::signals2::connection c = grabber_.registerCallback (f);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_grab_images.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ class OpenNIGrabFrame
depth_image_viewer_.registerMouseCallback (&OpenNIGrabFrame::mouse_callback, *this);
depth_image_viewer_.registerKeyboardCallback(&OpenNIGrabFrame::keyboard_callback, *this);

boost::function<void (const openni_wrapper::Image::Ptr&, const openni_wrapper::DepthImage::Ptr&, float) > image_cb = boost::bind (&OpenNIGrabFrame::image_callback, this, _1, _2, _3);
std::function<void (const openni_wrapper::Image::Ptr&, const openni_wrapper::DepthImage::Ptr&, float) > image_cb = boost::bind (&OpenNIGrabFrame::image_callback, this, _1, _2, _3);
boost::signals2::connection image_connection = grabber_.registerCallback (image_cb);

// start receiving point clouds
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_ii_normal_estimation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ class OpenNIIntegralImageNormalEstimation
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIIntegralImageNormalEstimation::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIIntegralImageNormalEstimation::cloud_cb, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.runOnVisualizationThread (boost::bind(&OpenNIIntegralImageNormalEstimation::viz_cb, this, _1), "viz_cb");
Expand Down
4 changes: 2 additions & 2 deletions apps/src/openni_klt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -206,14 +206,14 @@ class OpenNIViewer
void
run ()
{
boost::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&OpenNIViewer::cloud_callback, this, _1);
std::function<void (const CloudConstPtr&) > cloud_cb = boost::bind (&OpenNIViewer::cloud_callback, this, _1);
boost::signals2::connection cloud_connection = grabber_.registerCallback (cloud_cb);

boost::signals2::connection image_connection;
if (grabber_.providesCallback<void (const openni_wrapper::Image::Ptr&)>())
{
image_viewer_.reset (new pcl::visualization::ImageViewer ("Pyramidal KLT Tracker"));
boost::function<void (const openni_wrapper::Image::Ptr&) > image_cb = boost::bind (&OpenNIViewer::image_callback, this, _1);
std::function<void (const openni_wrapper::Image::Ptr&) > image_cb = boost::bind (&OpenNIViewer::image_callback, this, _1);
image_connection = grabber_.registerCallback (image_cb);
}

Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_mls_smoothing.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ class OpenNISmoothing
{
pcl::Grabber* interface = new pcl::OpenNIGrabber (device_id_);

boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNISmoothing::cloud_cb_, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNISmoothing::cloud_cb_, this, _1);
boost::signals2::connection c = interface->registerCallback (f);

viewer.registerKeyboardCallback (keyboardEventOccurred, reinterpret_cast<void*> (&stop_computing_));
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_mobile_server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ class PCLMobileServer
run ()
{
pcl::OpenNIGrabber grabber (device_id_);
boost::function<void (const CloudConstPtr&)> handler_function = boost::bind (&PCLMobileServer::handleIncomingCloud, this, _1);
std::function<void (const CloudConstPtr&)> handler_function = boost::bind (&PCLMobileServer::handleIncomingCloud, this, _1);
grabber.registerCallback (handler_function);
grabber.start ();

Expand Down
4 changes: 2 additions & 2 deletions apps/src/openni_octree_compression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ class SimpleOpenNIViewer
pcl::Grabber* interface = new pcl::OpenNIGrabber();

// make callback function from member function
boost::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
std::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
boost::bind (&SimpleOpenNIViewer::cloud_cb_, this, _1);

// connect callback function for desired signal. In this case its a point cloud with color values
Expand Down Expand Up @@ -210,7 +210,7 @@ struct EventHelper
pcl::Grabber* interface = new pcl::OpenNIGrabber ();

// make callback function from member function
boost::function<void
std::function<void
(const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f = boost::bind (&EventHelper::cloud_cb_, this, _1);

// connect callback function for desired signal. In this case its a point cloud with color values
Expand Down
6 changes: 3 additions & 3 deletions apps/src/openni_organized_compression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ class SimpleOpenNIViewer
pcl::Grabber* interface = new pcl::OpenNIGrabber();

// make callback function from member function
boost::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
std::function<void (const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f =
boost::bind (&SimpleOpenNIViewer::cloud_cb_, this, _1);

// connect callback function for desired signal. In this case its a point cloud with color values
Expand Down Expand Up @@ -246,7 +246,7 @@ struct EventHelper
pcl::Grabber* interface = new pcl::OpenNIGrabber ();

// make callback function from member function
boost::function<void
std::function<void
(const pcl::PointCloud<pcl::PointXYZRGBA>::ConstPtr&)> f = boost::bind (&EventHelper::cloud_cb_, this, _1);

// connect callback function for desired signal. In this case its a point cloud with color values
Expand All @@ -271,7 +271,7 @@ struct EventHelper
// Set the depth output format
grabber.getDevice ()->setDepthOutputFormat (static_cast<openni_wrapper::OpenNIDevice::DepthMode> (depthformat));

boost::function<void (const openni_wrapper::Image::Ptr&, const openni_wrapper::DepthImage::Ptr&, float) > image_cb
std::function<void (const openni_wrapper::Image::Ptr&, const openni_wrapper::DepthImage::Ptr&, float) > image_cb
= boost::bind (&EventHelper::image_callback, this, _1, _2, _3);
boost::signals2::connection image_connection = grabber.registerCallback (image_cb);

Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_organized_edge_detection.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ class OpenNIOrganizedEdgeDetection
{
pcl::Grabber* interface = new pcl::OpenNIGrabber ();

boost::function<void(const pcl::PointCloud<PointT>::ConstPtr&)> f = boost::bind (&OpenNIOrganizedEdgeDetection::cloud_cb_, this, _1);
std::function<void(const pcl::PointCloud<PointT>::ConstPtr&)> f = boost::bind (&OpenNIOrganizedEdgeDetection::cloud_cb_, this, _1);

// Make and initialize a cloud viewer
pcl::PointCloud<PointT>::Ptr init_cloud_ptr (new pcl::PointCloud<PointT>);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_organized_multi_plane_segmentation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ class OpenNIOrganizedMultiPlaneSegmentation
{
pcl::Grabber* interface = new pcl::OpenNIGrabber ();

boost::function<void(const pcl::PointCloud<PointT>::ConstPtr&)> f = boost::bind (&OpenNIOrganizedMultiPlaneSegmentation::cloud_cb_, this, _1);
std::function<void(const pcl::PointCloud<PointT>::ConstPtr&)> f = boost::bind (&OpenNIOrganizedMultiPlaneSegmentation::cloud_cb_, this, _1);

//make a viewer
pcl::PointCloud<PointT>::Ptr init_cloud_ptr (new pcl::PointCloud<PointT>);
Expand Down
2 changes: 1 addition & 1 deletion apps/src/openni_passthrough.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ OpenNIPassthrough::OpenNIPassthrough (pcl::OpenNIGrabber& grabber)
ui_->qvtk_widget->update ();

// Start the OpenNI data acquision
boost::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIPassthrough::cloud_cb, this, _1);
std::function<void (const CloudConstPtr&)> f = boost::bind (&OpenNIPassthrough::cloud_cb, this, _1);
boost::signals2::connection c = grabber_.registerCallback (f);

grabber_.start ();
Expand Down
Loading