CGAL 6.2 - IO Streams
Loading...
Searching...
No Matches
GLTF I/O Functions

I/O Functions for the GLTF File Format.

Functions

template<typename PointRange , typename PolygonRange >
bool CGAL::IO::read_GLTF (const std::string &filename, PointRange &points, PolygonRange &polygons)
 reads the content of the file fname into points and polygons, using the GLTF File Format.
 

Function Documentation

◆ read_GLTF()

template<typename PointRange , typename PolygonRange >
bool CGAL::IO::read_GLTF ( const std::string &  filename,
PointRange &  points,
PolygonRange &  polygons 
)

#include <CGAL/IO/GLTF.h>

reads the content of the file fname into points and polygons, using the GLTF File Format.

Attention
The polygon soup is not cleared, and the data from the file are appended.
Template Parameters
PointRangea model of the concept RandomAccessContainer whose value type is the point type.
PolygonRangea model of the concepts SequenceContainer and BackInsertionSequence whose value_type is itself a model of the concept SequenceContainer and BackInsertionSequence whose value_type is an unsigned integer type convertible to std::size_t
Parameters
filenamethe path to the input file
pointspoints of the soup of polygons
polygonsa range of polygons. Each element in it describes a polygon using the indices of the points in points.
Returns
true if the reading was successful, false otherwise.