|
| template<typename PointRange , typename PolygonRange , typename NamedParameters = CGAL::parameters::Default_named_parameters> |
| bool | CGAL::IO::read_polygon_soup (const std::string &fname, PointRange &points, PolygonRange &polygons, const NamedParameters &np=parameters::default_values()) |
| | reads a polygon soup from a file.
|
| |
| template<typename PointRange , typename PolygonRange , typename NamedParameters = CGAL::parameters::Default_named_parameters> |
| bool | CGAL::IO::write_polygon_soup (const std::string &fname, const PointRange &points, const PolygonRange &polygons, const NamedParameters &np=parameters::default_values()) |
| | writes the content of points and polygons in a file.
|
| |
template<typename PointRange , typename PolygonRange , typename NamedParameters = CGAL::parameters::Default_named_parameters>
| bool CGAL::IO::write_polygon_soup |
( |
const std::string & |
fname, |
|
|
const PointRange & |
points, |
|
|
const PolygonRange & |
polygons, |
|
|
const NamedParameters & |
np = parameters::default_values() |
|
) |
| |
#include <CGAL/IO/polygon_soup_io.h>
writes the content of points and polygons in a file.
Supported file formats are the following:
The format is detected from the filename extension (letter case is not important).
- Template Parameters
-
- Parameters
-
| fname | the name of the file. |
| points | points of the soup of polygons |
| polygons | each element in the range describes a polygon using the indices of the vertices. |
| np | optional Named Parameters described below |
- Optional Named Parameters
-
a property map associating points to the elements of the range
points
-
Type: a model of
ReadablePropertyMap whose key type is the value type of the iterator of PointRange and value type is a model of concept Point_3
-
Default:
CGAL::Identity_property_map<std::iterator_traits<PointRange::iterator>::value_type>
| |
-
indicates whether output warnings and error messages should be printed or not.
-
Type: Boolean
-
Default:
false
| |
- Returns
true if writing was successful, false otherwise.