Loading...
Searching...
No Matches
pcl::IFSReader Class Reference
Module io

Indexed Face set (IFS) file format reader. More...

`#include <pcl/io/ifs_io.h>`

## Public Types

enum | { IFS_V1_0 = 0 , IFS_V1_1 = 1 }
| we support two versions 1.0 classic 1.1 with texture coordinates addon More...

## Public Member Functions

| IFSReader ()=default
| Empty constructor.
| ~IFSReader ()=default
| Empty destructor.
int | readHeader (const std::string &file_name, pcl::PCLPointCloud2 &cloud, int &ifs_version, unsigned int &data_idx)
| Read a point cloud data header from an IFS file.
int | read (const std::string &file_name, pcl::PCLPointCloud2 &cloud, int &ifs_version)
| Read a point cloud data from an IFS file and store it into a pcl/PCLPointCloud2.
int | read (const std::string &file_name, pcl::PolygonMesh &mesh, int &ifs_version)
| Read a point cloud data from an IFS file and store it into a PolygonMesh.
template<typename PointT>
int | read (const std::string &file_name, pcl::PointCloud< PointT > &cloud)
| Read a point cloud data from an IFS file, and convert it to the given template pcl::PointCloud format.

## Detailed Description

Indexed Face set (IFS) file format reader.

This file format is used for the Brown Mesh Set for instance.

Author
  Nizar Sallem

Definition at line 52 of file ifs_io.h.

## Member Enumeration Documentation

## anonymous enum

anonymous enum

we support two versions 1.0 classic 1.1 with texture coordinates addon

Enumerator
IFS_V1_0 |
IFS_V1_1 |

Definition at line 64 of file ifs_io.h.

## Constructor & Destructor Documentation

## IFSReader()

pcl::IFSReader::IFSReader | ( |  | ) |

default

Empty constructor.

## ~IFSReader()

pcl::IFSReader::~IFSReader | ( |  | ) |

default

Empty destructor.

## Member Function Documentation

## read() [1/3]

int pcl::IFSReader::read | ( | const std::string & | file_name,
|  | pcl::PCLPointCloud2 & | cloud,
|  | int & | ifs_version )

Read a point cloud data from an IFS file and store it into a pcl/PCLPointCloud2.

Parameters

  [in] | file_name | the name of the file containing the actual PointCloud data
  [out] | cloud | the resultant PCLPointCloud2 blob read from disk
  [out] | ifs_version | the IFS version of the file (either IFS_V1_0 or IFS_V1_1)

Returns
  - < 0 (-1) on error
  - == 0 on success

Referenced by pcl::io::loadIFSFile(), pcl::io::loadIFSFile(), pcl::io::loadIFSFile(), and read().

## read() [2/3]

template<typename PointT>

int pcl::IFSReader::read | ( | const std::string & | file_name,
|  | pcl::PointCloud< PointT > & | cloud )

inline

Read a point cloud data from an IFS file, and convert it to the given template pcl::PointCloud format.

Parameters

  [in] | file_name | the name of the file containing the actual PointCloud data
  [out] | cloud | the resultant PointCloud message read from disk

Returns
  - < 0 (-1) on error
  - == 0 on success

Definition at line 123 of file ifs_io.h.

References pcl::fromPCLPointCloud2(), read(), pcl::PointCloud< PointT >::sensor_orientation_, and pcl::PointCloud< PointT >::sensor_origin_.

## read() [3/3]

int pcl::IFSReader::read | ( | const std::string & | file_name,
|  | pcl::PolygonMesh & | mesh,
|  | int & | ifs_version )

Read a point cloud data from an IFS file and store it into a PolygonMesh.

Parameters

  [in] | file_name | the name of the file containing the mesh data
  [out] | mesh | the resultant PolygonMesh
  [out] | ifs_version | the IFS version of the file (either IFS_V1_0 or IFS_V1_1)

Returns
  - < 0 (-1) on error
  - == 0 on success

## readHeader()

int pcl::IFSReader::readHeader | ( | const std::string & | file_name,
|  | pcl::PCLPointCloud2 & | cloud,
|  | int & | ifs_version,
|  | unsigned int & | data_idx )

Read a point cloud data header from an IFS file.

Load only the meta information (number of points, their types, etc), and not the points themselves, from a given IFS file. Useful for fast evaluation of the underlying data structure.

Parameters

  [in] | file_name | the name of the file to load
  [out] | cloud | the resultant point cloud dataset (only header will be filled)
  [out] | ifs_version | the IFS version of the file (IFS_V1_0 or IFS_V1_1)
  [out] | data_idx | the offset of cloud data within the file

Returns
  - < 0 (-1) on error
  - == 0 on success

The documentation for this class was generated from the following file:

- pcl/io/ifs_io.h