\( \newcommand{\E}{\mathrm{E}} \) \( \newcommand{\A}{\mathrm{A}} \) \( \newcommand{\R}{\mathrm{R}} \) \( \newcommand{\N}{\mathrm{N}} \) \( \newcommand{\Q}{\mathrm{Q}} \) \( \newcommand{\Z}{\mathrm{Z}} \) \( \def\ccSum #1#2#3{ \sum_{#1}^{#2}{#3} } \def\ccProd #1#2#3{ \sum_{#1}^{#2}{#3} }\)
CGAL 4.10.2 - Point Set Processing
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
PlyInterpreter Concept Reference

Definition

A PLY interpreter describes how to process a PLY input based on its headers informations. More specifically, it must specify the properties expected for each point and where to store them once read.

Has Models:
CGAL::Ply_interpreter_points_and_normals_3

Public Member Functions

bool is_applicable (Ply_reader &reader)
 Check if expected properties are found in the PLY reader. More...
 
void process_line (Ply_reader &reader)
 Assign read properties to appropriate containers or classes. More...
 

Member Function Documentation

bool PlyInterpreter::is_applicable ( Ply_reader &  reader)

Check if expected properties are found in the PLY reader.

If this function returns false, then read_ply_custom_points() will not read anything from the input stream.

Note that although the PLY header specifies the order in which the tag attributes should appear in the file, the attributes in the Ply_reader are only identified by their type and tag, not by their position in the header.

Parameters
readerPly_reader to which the interpreter is expected to be applied
Returns
true if the provided reader matches the requirements of the interpreter, false otherwise.
void PlyInterpreter::process_line ( Ply_reader &  reader)

Assign read properties to appropriate containers or classes.

Note that in a PLY input, one point occupies exactly one line (with all properties separated by white spaces): this method aims at processing one point along with its potential attributes.

Parameters
readerPly_reader used to read PLY input