High-level operations.
#include<CGAL/Linear_cell_complex/IO/VTK.h>
|
| template<typename LCC , typename VertexScalarType , typename VolumeScalarType > |
| bool | CGAL::IO::read_VTK (const char *filename, LCC &alcc, std::vector< VertexScalarType > *vertex_scalars=nullptr, std::vector< VolumeScalarType > *volume_scalars=nullptr) |
| | Reads a VTK legacy ASCII file and load it into a 3D linear cell complex.
|
| |
| template<typename LCC , typename VertexScalarType , typename VolumeScalarType > |
| bool | CGAL::IO::write_VTK (const char *filename, const LCC &alcc, const std::vector< VertexScalarType > *vertex_scalars=nullptr, const std::vector< VolumeScalarType > *volume_scalars=nullptr) |
| | Writes a 3D Linear_cell_complex to a VTK legacy ASCII file.
|
| |
◆ read_VTK()
template<typename LCC , typename VertexScalarType , typename VolumeScalarType >
| bool CGAL::IO::read_VTK |
( |
const char * |
filename, |
|
|
LCC & |
alcc, |
|
|
std::vector< VertexScalarType > * |
vertex_scalars = nullptr, |
|
|
std::vector< VolumeScalarType > * |
volume_scalars = nullptr |
|
) |
| |
#include <CGAL/Linear_cell_complex/IO/VTK.h>
Reads a VTK legacy ASCII file and load it into a 3D linear cell complex.
- Template Parameters
-
- Parameters
-
| filename | Path to the VTK file |
| alcc | The linear cell complex to populate (will be cleared first) |
| vertex_scalars | Optional output vector to store per-vertex scalar values. If provided, will be resized to match number of vertices. |
| volume_scalars | Optional output vector to store per-volume scalar values. If provided, will be resized to match number of volumes. |
- Returns
true if loading was successful, false otherwise
◆ write_VTK()
template<typename LCC , typename VertexScalarType , typename VolumeScalarType >
| bool CGAL::IO::write_VTK |
( |
const char * |
filename, |
|
|
const LCC & |
alcc, |
|
|
const std::vector< VertexScalarType > * |
vertex_scalars = nullptr, |
|
|
const std::vector< VolumeScalarType > * |
volume_scalars = nullptr |
|
) |
| |
#include <CGAL/Linear_cell_complex/IO/VTK.h>
Writes a 3D Linear_cell_complex to a VTK legacy ASCII file.
- Template Parameters
-
- Parameters
-
| filename | Path to the output VTK file |
| alcc | The linear cell complex to export |
| vertex_scalars | Optional per-vertex scalar data. If provided, must have same size as number of vertex attributes in the LCC. |
| volume_scalars | Optional per-volume scalar data. If provided, must have same size as number of 3-cells in the LCC. |
- Returns
true if writing was successful, false otherwise
- Examples
- Linear_cell_complex/linear_cell_complex_3_vtk_io.cpp.