https://github.com/patr-schm/surface-maps-via-adaptive-triangulations
Tip revision: da768497f0b8a84088b7f0d839b8b40a1780c672 authored by Patrick Schmidt on 11 May 2023, 16:25:14 UTC
Add grsi-thumbnail.png
Add grsi-thumbnail.png
Tip revision: da76849
Geometries.cc
/*
* This file is part of
* Surface Maps via Adaptive Triangulations
* (https://github.com/patr-schm/surface-maps-via-adaptive-triangulations)
* and is released under the MIT license.
*
* Authors: Patrick Schmidt, Janis Born
*/
#include "Geometries.hh"
namespace SurfaceMaps
{
Geometry which_geometry(const TriMesh& _mesh)
{
if (closed_surface(_mesh))
{
if (genus(_mesh) == 0)
return Spherical;
else if (genus(_mesh) == 1)
return Planar;
else if (genus(_mesh) >= 2)
return Hyperbolic;
else
ISM_ERROR_throw("");
}
else
{
return Planar;
}
}
}
