I/O Functions for the GOCAD (TS) File Format.
|
template<typename Graph , typename NamedParameters > |
bool | CGAL::IO::read_GOCAD (std::istream &is, std::pair< std::string, std::string > &name_and_color, Graph &g, const NamedParameters &np) |
| reads the graph g from the input stream, using the GOCAD (TS) File Format. More...
|
|
template<typename Graph , typename NamedParameters > |
bool | CGAL::IO::read_GOCAD (const std::string &fname, std::pair< std::string, std::string > &name_and_color, Graph &g, const NamedParameters &np) |
| reads the graph g from the file fname , using the GOCAD (TS) File Format. More...
|
|
template<typename Graph , typename NamedParameters > |
bool | CGAL::IO::write_GOCAD (std::ostream &os, const char *name, const Graph &g, const NamedParameters &np) |
| writes the graph g into the output stream os , using the GOCAD (TS) File Format. More...
|
|
template<typename Graph , typename NamedParameters > |
bool | CGAL::IO::write_GOCAD (std::ostream &os, const Graph &g, const NamedParameters &np) |
| writes the graph g in the GOCAD (TS) File Format into os . More...
|
|
template<typename Graph , typename NamedParameters > |
bool | CGAL::IO::write_GOCAD (const std::string &fname, const Graph &g, const NamedParameters &np) |
| writes the graph g into a file named fname , using the GOCAD (TS) File Format. More...
|
|
◆ read_GOCAD() [1/2]
template<typename Graph , typename NamedParameters >
bool CGAL::IO::read_GOCAD |
( |
std::istream & |
is, |
|
|
std::pair< std::string, std::string > & |
name_and_color, |
|
|
Graph & |
g, |
|
|
const NamedParameters & |
np |
|
) |
| |
#include <CGAL/boost/graph/IO/GOCAD.h>
reads the graph g
from the input stream, using the GOCAD (TS) File Format.
The data is expected to represent a 2-manifold (possibly with borders).
- Attention
- The graph
g
is not cleared, and the data from the stream are appended.
- Template Parameters
-
- Parameters
-
is | the input stream |
name_and_color | name and color of the mesh |
g | the graph to be built from the input data |
np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the vertices of
g
-
Type: a class model of
WritablePropertyMap with boost::graph_traits<Graph>::vertex_descriptor as key type and Point_3 as value type
-
Default:
boost::get(CGAL::vertex_point, g)
-
Extra: If this parameter is omitted, an internal property map for
CGAL::vertex_point_t must be available in Graph .
|
|
-
whether extra information is printed when an incident occurs during reading
-
Type: Boolean
-
Default:
false
| |
- Returns
true
if reading was successful and the resulting mesh is valid, false
otherwise.
◆ read_GOCAD() [2/2]
template<typename Graph , typename NamedParameters >
bool CGAL::IO::read_GOCAD |
( |
const std::string & |
fname, |
|
|
std::pair< std::string, std::string > & |
name_and_color, |
|
|
Graph & |
g, |
|
|
const NamedParameters & |
np |
|
) |
| |
#include <CGAL/boost/graph/IO/GOCAD.h>
reads the graph g
from the file fname
, using the GOCAD (TS) File Format.
The data is expected to represent a 2-manifold (possibly with borders).
- Attention
- The graph
g
is not cleared, and the data from the file are appended.
- Template Parameters
-
- Parameters
-
fname | the name of the input file |
name_and_color | name and color of the mesh |
g | the graph to be built from the input data |
np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the vertices of
g
-
Type: a class model of
WritablePropertyMap with boost::graph_traits<Graph>::vertex_descriptor as key type and Point_3 as value type
-
Default:
boost::get(CGAL::vertex_point, g)
-
Extra: If this parameter is omitted, an internal property map for
CGAL::vertex_point_t must be available in Graph .
|
|
-
whether extra information is printed when an incident occurs during reading
-
Type: Boolean
-
Default:
false
| |
- See also
- Overloads of this function for specific models of the concept
FaceGraph
.
- Returns
true
if reading was successful and the resulting mesh is valid, false
otherwise.
◆ write_GOCAD() [1/3]
template<typename Graph , typename NamedParameters >
bool CGAL::IO::write_GOCAD |
( |
std::ostream & |
os, |
|
|
const char * |
name, |
|
|
const Graph & |
g, |
|
|
const NamedParameters & |
np |
|
) |
| |
#include <CGAL/boost/graph/IO/GOCAD.h>
writes the graph g
into the output stream os
, using the GOCAD (TS) File Format.
- Template Parameters
-
- Parameters
-
os | the output stream |
name | the name that will be assigned to g in the output file |
g | the graph to be written |
np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the vertices of
g
-
Type: a class model of
ReadablePropertyMap with boost::graph_traits<Graph>::vertex_descriptor as key type and Point_3 as value type
-
Default:
boost::get(CGAL::vertex_point, g)
-
Extra: If this parameter is omitted, an internal property map for
CGAL::vertex_point_t must be available in Graph .
|
|
-
a parameter used to set the precision (i.e. how many digits are generated) of the output stream
-
Type: int
-
Default:
the precision of the stream os``
| |
- Returns
true
if writing was successful, false
otherwise.
◆ write_GOCAD() [2/3]
template<typename Graph , typename NamedParameters >
bool CGAL::IO::write_GOCAD |
( |
std::ostream & |
os, |
|
|
const Graph & |
g, |
|
|
const NamedParameters & |
np |
|
) |
| |
#include <CGAL/boost/graph/IO/GOCAD.h>
writes the graph g
in the GOCAD (TS) File Format into os
.
The name assigned to g
in the output is anonymous
.
- Template Parameters
-
- Parameters
-
os | the output stream |
g | the graph to be written |
np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the vertices of
g
-
Type: a class model of
ReadablePropertyMap with boost::graph_traits<Graph>::vertex_descriptor as key type and Point_3 as value type
-
Default:
boost::get(CGAL::vertex_point, g)
-
Extra: If this parameter is omitted, an internal property map for
CGAL::vertex_point_t must be available in Graph .
|
|
-
a parameter used to set the precision (i.e. how many digits are generated) of the output stream
-
Type: int
-
Default:
the precision of the stream os``
| |
- Returns
true
if writing was successful, false
otherwise.
◆ write_GOCAD() [3/3]
template<typename Graph , typename NamedParameters >
bool CGAL::IO::write_GOCAD |
( |
const std::string & |
fname, |
|
|
const Graph & |
g, |
|
|
const NamedParameters & |
np |
|
) |
| |
#include <CGAL/boost/graph/IO/GOCAD.h>
writes the graph g
into a file named fname
, using the GOCAD (TS) File Format.
In this overload, fname
is used as the name of the graph within the file.
- Template Parameters
-
- Parameters
-
fname | the name of the output file |
g | the graph to be written |
np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the vertices of
g
-
Type: a class model of
ReadablePropertyMap with boost::graph_traits<Graph>::vertex_descriptor as key type and Point_3 as value type
-
Default:
boost::get(CGAL::vertex_point, g)
-
Extra: If this parameter is omitted, an internal property map for
CGAL::vertex_point_t must be available in Graph .
|
|
-
a parameter used to set the precision (i.e. how many digits are generated) of the output stream
-
Type: int
-
Default:
6
| |
- See also
- Overloads of this function for specific models of the concept
FaceGraph
.