IO Functions and classes that are dependant on scalar type are defined in this templatized class. More...
#include <IO.h>
Classes | |
struct | CsvDescriptor |
A structure to hold information about descriptors contained in a CSV file. More... | |
struct | FileInfo |
Information to exploit a reading from a file using this library. Fields might be left blank if unused. More... | |
struct | FileInfoVector |
A vector of file info, to be used in batch processing. More... | |
class | PLYElement |
Interface for all PLY elements. Implementations must provide definition of getPMType() More... | |
class | PLYElementF |
Factory for PLY elements. More... | |
struct | PLYProperty |
Interface for PLY property. More... | |
class | PLYVertex |
Implementation of PLY vertex element. More... | |
Public Types | |
typedef PointMatcher< T > ::DataPoints | DataPoints |
alias | |
typedef std::map< std::string, DescAssociationPair > | DescAssociationMap |
typedef std::pair< int, std::string > | DescAssociationPair |
Pair descriptor column, descriptor name. | |
typedef PointMatcher< T > ::DataPoints::Label | Label |
alias | |
typedef PointMatcher< T >::Matrix | Matrix |
alias | |
typedef PointMatcher< T >::Matrix | Parameters |
alias | |
typedef std::map< std::string, std::vector< PLYProperty > > | PLYDescPropMap |
enum | SupportedVTKDataTypes { POLYDATA, UNSTRUCTURED_GRID } |
Enumeration of legacy VTK data types that can be parsed. More... | |
typedef PointMatcher< T > ::TransformationParameters | TransformationParameters |
alias | |
typedef PointMatcher< T >::Vector | Vector |
alias | |
Static Public Member Functions | |
static bool | colLabelRegistered (const std::string &colLabel) |
returns true if a particular descriptor dim label is registered (ie nx, red...) | |
static std::string | getColLabel (const Label &label, const int row) |
convert a descriptor label to an appropriate sub-label | |
static DescAssociationMap | getDescAssocationMap () |
map to store association between common 1d descriptor labels and their PM label and span dimension | |
static DescAssociationPair | getDescAssociationPair (const std::string &colLabel) |
get PM descriptor label associated with sublabel colLabel | |
static DataPoints | loadCSV (const std::string &fileName) |
Load comma separated values (csv) file. | |
static DataPoints | loadCSV (std::istream &is) |
Load comma separated values (csv) file. | |
static DataPoints | loadPCD (const std::string &fileName) |
static DataPoints | loadPCD (std::istream &is) |
Load PCD file. | |
static DataPoints | loadPLY (const std::string &fileName) |
Load polygon file format (ply) file. | |
static DataPoints | loadPLY (std::istream &is) |
Load polygon file format (PLY) file. | |
static DataPoints | loadVTK (const std::string &fileName) |
Load point cloud from a file as VTK. | |
static DataPoints | loadVTK (std::istream &is) |
Load point cloud from a stream as VTK. | |
static bool | plyPropTypeValid (const std::string &type) |
Check that property defined by type is a valid PLY type note: type must be lowercase. | |
static void | saveCSV (const DataPoints &data, const std::string &fileName) |
Save point cloud to a file as CSV. | |
static void | saveCSV (const DataPoints &data, std::ostream &os) |
Save point cloud to a stream as CSV. | |
static void | savePCD (const DataPoints &data, const std::string &fileName) |
save datapoints to PCD point cloud format | |
static void | savePLY (const DataPoints &data, const std::string &fileName) |
save datapoints to PLY point cloud format | |
static void | saveVTK (const DataPoints &data, const std::string &fileName) |
Save point cloud to a file as VTK. |
IO Functions and classes that are dependant on scalar type are defined in this templatized class.
typedef PointMatcher<T>::DataPoints PointMatcherIO< T >::DataPoints |
typedef std::map<std::string, DescAssociationPair > PointMatcherIO< T >::DescAssociationMap |
typedef std::pair<int, std::string > PointMatcherIO< T >::DescAssociationPair |
typedef PointMatcher<T>::DataPoints::Label PointMatcherIO< T >::Label |
typedef PointMatcher<T>::Matrix PointMatcherIO< T >::Matrix |
typedef PointMatcher<T>::Matrix PointMatcherIO< T >::Parameters |
typedef std::map<std::string, std::vector<PLYProperty> > PointMatcherIO< T >::PLYDescPropMap |
typedef PointMatcher<T>::TransformationParameters PointMatcherIO< T >::TransformationParameters |
typedef PointMatcher<T>::Vector PointMatcherIO< T >::Vector |
enum PointMatcherIO::SupportedVTKDataTypes |
bool PointMatcherIO< T >::colLabelRegistered | ( | const std::string & | colLabel | ) | [static] |
std::string PointMatcherIO< T >::getColLabel | ( | const Label & | label, |
const int | row | ||
) | [static] |
PointMatcherIO< T >::DescAssociationMap PointMatcherIO< T >::getDescAssocationMap | ( | ) | [static] |
PointMatcherIO< T >::DescAssociationPair PointMatcherIO< T >::getDescAssociationPair | ( | const std::string & | colLabel | ) | [static] |
template PointMatcher< double >::DataPoints PointMatcherIO< T >::loadCSV | ( | const std::string & | fileName | ) | [static] |
Load comma separated values (csv) file.
fileName | a string containing the path and the file name |
This loader has 3 behaviors since there is no official standard for csv files. A 2D or 3D point cloud will be created automatically if:
Otherwise, the user is asked to enter column id manually which might block automatic processing.
PointMatcher< T >::DataPoints PointMatcherIO< T >::loadCSV | ( | std::istream & | is | ) | [static] |
static DataPoints PointMatcherIO< T >::loadPCD | ( | const std::string & | fileName | ) | [static] |
PointMatcherIO< T >::DataPoints PointMatcherIO< T >::loadPCD | ( | std::istream & | is | ) | [static] |
PointMatcherIO< T >::DataPoints PointMatcherIO< T >::loadPLY | ( | const std::string & | fileName | ) | [static] |
Load polygon file format (ply) file.
fileName | a string containing the path and the file name |
Note: that the PLY does not define a standard for point clouds Warning: Binary PLY files are not supported, only ASCII Only PLY files with elements named "vertex" are supported "vertex" should have 2 or 3 properties names "x", "y", "z" to define features.
PointMatcherIO< T >::DataPoints PointMatcherIO< T >::loadPLY | ( | std::istream & | is | ) | [static] |
template PointMatcherIO< double >::DataPoints PointMatcherIO< T >::loadVTK | ( | const std::string & | fileName | ) | [static] |
PointMatcher< T >::DataPoints PointMatcherIO< T >::loadVTK | ( | std::istream & | is | ) | [static] |
bool PointMatcherIO< T >::plyPropTypeValid | ( | const std::string & | type | ) | [static] |
template void PointMatcherIO< T >::saveCSV | ( | const DataPoints & | data, |
const std::string & | fileName | ||
) | [static] |
void PointMatcherIO< T >::saveCSV | ( | const DataPoints & | data, |
std::ostream & | os | ||
) | [static] |
template void PointMatcherIO< T >::savePCD | ( | const DataPoints & | data, |
const std::string & | fileName | ||
) | [static] |
template void PointMatcherIO< T >::savePLY | ( | const DataPoints & | data, |
const std::string & | fileName | ||
) | [static] |
template void PointMatcherIO< T >::saveVTK | ( | const DataPoints & | data, |
const std::string & | fileName | ||
) | [static] |