peng
peng

Reputation: 11

How to check the header files required while using a PCL function?

PCL API Documentation Here is the PCL API Documentation, for example, which header files are required while using the function pcl::io::loadPolygonFile?

Upvotes: 0

Views: 128

Answers (2)

Ardiya
Ardiya

Reputation: 725

Similar to Jing Zhao's answer, which is basically searching through the code, you can also use Github advanced search as shown in the picture below. enter image description here

If you're too lazy, you can also change the query q=loadPolygonFile in the link below to anything else https://github.com/search?q=loadPolygonFile+repo%3APointCloudLibrary%2Fpcl+extension%3Ah+extension%3Ahpp&type=Code&ref=advsearch

Upvotes: 0

Jing Zhao
Jing Zhao

Reputation: 2672

Wellcome to Stack Overflow!

Well, if the documentation does not list the required header, I would definitely turn to the source code and using grep :)


As for your concrete example, I would:

  • First, change into the directory where pcl source code stays, for my computer it's:
    cd ~/library/pcl-pcl-1.9.1/.
  • Then, go to the directory where the header of the io module resides, that would be:
    cd io/include/pcl/io/
  • Last, grep -ir "loadpolygonfile"

And it turns out the header should be vtk_lib_io.h :)
Hope it helps!

Upvotes: 1

Related Questions