CGAL 6.0.1 - Surface Mesh Topology
Loading...
Searching...
No Matches
Draw a Mesh with Paths

#include<CGAL/draw_face_graph_with_paths.h>

Functions

template<class Mesh , class GSOptions >
void CGAL::draw (const Mesh &amesh, const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &apaths, const GSOptions &gso)
 opens a new window and draws amesh, either a 2D linear cell complex or a model of the FaceGraph concept, plus the paths lying on this mesh given in apaths.
 
template<class Mesh >
void CGAL::draw (const Mesh &amesh, const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &apaths)
 A shortcut to CGAL::draw(amesh, apaths, Graphics_scene_options_face_graph_with_paths{}).
 
template<class Mesh , class GSOptions >
void CGAL::draw (const Mesh &amesh, std::initializer_list< Path_on_surface< Mesh > > apaths, const GSOptions &gso)
 Same function than draw() but taking the paths from a list instead from an std::vector.
 
template<class Mesh >
void CGAL::draw (const Mesh &amesh, std::initializer_list< Path_on_surface< Mesh > > apaths)
 A shortcut to CGAL::draw(amesh, apaths, Graphics_scene_options_face_graph_with_paths{}).
 
template<class Mesh , class GSOptions >
void CGAL::add_to_graphics_scene (const Mesh &amesh, CGAL::Graphics_scene &gs, const GSOptions &gso, const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &apaths)
 adds the vertices, edges and faces of amesh, either a 2D linear cell complex or a model of the FaceGraph concept, plus the paths lying on this mesh given in apaths, into the given graphic scene gs.
 
template<class Mesh >
void CGAL::add_to_graphics_scene (const Mesh &amesh, CGAL::Graphics_scene &gs, const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &apaths)
 A shortcut to CGAL::add_to_graphics_scene(amesh, gs, Graphics_scene_options_face_graph_with_paths{}, apaths).
 
template<class Mesh , class GSOptions >
void CGAL::add_to_graphics_scene (const Mesh &amesh, CGAL::Graphics_scene &gs, const GSOptions &gso, std::initializer_list< Path_on_surface< Mesh > > apaths)
 Same function than add_to_graphics_scene() but taking the paths from a list instead from an std::vector.
 
template<class Mesh >
void CGAL::add_to_graphics_scene (const Mesh &amesh, CGAL::Graphics_scene &gs, std::initializer_list< Path_on_surface< Mesh > > apaths)
 A shortcut to CGAL::add_to_graphics_scene(amesh, gs, Graphics_scene_options_face_graph_with_paths{}, apaths).
 

Function Documentation

◆ add_to_graphics_scene()

template<class Mesh , class GSOptions >
void CGAL::add_to_graphics_scene ( const Mesh &  amesh,
CGAL::Graphics_scene &  gs,
const GSOptions &  gso,
const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &  apaths 
)

#include <CGAL/draw_face_graph_with_paths.h>

adds the vertices, edges and faces of amesh, either a 2D linear cell complex or a model of the FaceGraph concept, plus the paths lying on this mesh given in apaths, into the given graphic scene gs.

Parameters of the cells are taken from the optional graphics scene options parameter gso. Note that gs is not cleared before being filled (to enable to draw several data structures in the same basic viewer).

Template Parameters
Mesheither a 2D linear cell complex or a model of the FaceGraph concept.
GSOptionsa model of GraphicsSceneOptionsFaceGraphWithPaths concept.
Parameters
ameshthe mesh to draw.
gsthe graphic scene to fill.
gsothe graphics scene options parameter.
apathsthe paths to draw, which should lie on amesh.

◆ draw()

template<class Mesh , class GSOptions >
void CGAL::draw ( const Mesh &  amesh,
const std::vector< Surface_mesh_topology::Path_on_surface< Mesh > > &  apaths,
const GSOptions &  gso 
)

#include <CGAL/draw_face_graph_with_paths.h>

opens a new window and draws amesh, either a 2D linear cell complex or a model of the FaceGraph concept, plus the paths lying on this mesh given in apaths.

Parameters of the drawing are taken from the optional graphics scene options parameter.

A call to this function blocks the execution of the program until the drawing window is closed. This function requires CGAL_Qt6, and is only available if the macro CGAL_USE_BASIC_VIEWER is defined. Linking with the cmake target CGAL::CGAL_Basic_viewer will link with CGAL_Qt6 and add the definition CGAL_USE_BASIC_VIEWER.

Template Parameters
Mesheither a 2D linear cell complex or a model of the FaceGraph concept.
GSOptionsa model of GraphicsSceneOptionsFaceGraphWithPaths concept.
Parameters
ameshthe mesh to draw.
apathsthe paths to draw, which should lie on amesh.
gsothe graphics scene options parameter.