thư viện point cloud , C++, open CV . bị lỗi

các ace có thể chỉ lỗi sai hộ mình với. mình đang cần gấp ạ

  • 500

    Votes: 0 0.0%
  • 500

    Votes: 0 0.0%

  • Total voters
    0

denchetmatthoi

Trứng gà
mình đang dùng kinect kết nối PC. viết bằng C++ . đây là code nó bị một số lỗi . các ace có thể giúp mình dc không?

#include <iostream>
#include "pcl/io/openni_grabber.h"
#include "pcl/visualization/cloud_viewer.h"
using namespace std;
class SimpleOpenNIViewer

{
public:

SimpleOpenNIViewer () : viewer ("PCL OpenNI Viewer") {}


void cloud_cb_ (const pcl ::PointCloud <pcl::PointXYZRGB> ::ConstPtr &cloud)

{

if (!viewer.wasStopped())

viewer.showCloud (cloud);

}



void run ()

{

pcl ::Grabber* interface = new pcl::OpenNIGrabber();
boost std ::function<void (const pcl::PointCloud<pcl::PointXYZRGB>::ConstPtr&)> f = boost::bind


(&SimpleOpenNIViewer::cloud_cb_, this, _1);

interface->registerCallback (f);


interface->start ();


while (!viewer.wasStopped())

{

boost::this_thread::sleep (boost::posix_time::seconds (1));

}



interface->stop ();

}



pcl::visualization::CloudViewer viewer;

};



int main ()

{

SimpleOpenNIViewer v;

v.run ();

return 0;

}

đây là lỗi báo về .

1 IntelliSense: cannot open source file "pcl/io/openni_grabber.h" 2
2 IntelliSense: cannot open source file "pcl/visualization/cloud_viewer.h" 3
4 IntelliSense: expected a ')' 17
11 IntelliSense: expected a ';' 34
9 IntelliSense: identifier "boost" is undefined 34
5 IntelliSense: identifier "cloud" is undefined 23
12 IntelliSense: identifier "f" is undefined 35
7 IntelliSense: identifier "interface" is undefined 33
3 IntelliSense: name followed by '::' must be a class or namespace name 17
6 IntelliSense: name followed by '::' must be a class or namespace name 33
8 IntelliSense: name followed by '::' must be a class or namespace name 33
13 IntelliSense: name followed by '::' must be a class or namespace name 41
14 IntelliSense: name followed by '::' must be a class or namespace name 41
15 IntelliSense: name followed by '::' must be a class or namespace name 53
10 IntelliSense: namespace "std" has no member "function" 34



cảm ơn các ace nhiều.

 
Top