Unravel Engine C++ Reference
Loading...
Searching...
No Matches
generator::parametric_mesh_t Class Reference

A mesh with values evaluated using a callback function. More...

#include <parametric_mesh.hpp>

Classes

class  triangles_t
 
class  vertices_t
 

Public Member Functions

 parametric_mesh_t (const std::function< mesh_vertex_t(const gml::dvec2 &t)> &eval, const gml::ivec2 &segments={16, 16}) noexcept
 
triangles_t triangles () const noexcept
 
vertices_t vertices () const noexcept
 

Detailed Description

A mesh with values evaluated using a callback function.

Definition at line 13 of file parametric_mesh.hpp.

Constructor & Destructor Documentation

◆ parametric_mesh_t()

parametric_mesh_t::parametric_mesh_t ( const std::function< mesh_vertex_t(const gml::dvec2 &t)> & eval,
const gml::ivec2 & segments = {16, 16} )
explicitnoexcept
Parameters
evalA callback that returns a MeshVertex for a given value.
segmentsThe number of segments along the surface. Both should be >= 1. If either is zero an empty mesh is generated.

Definition at line 87 of file parametric_mesh.cpp.

Member Function Documentation

◆ triangles()

parametric_mesh_t::triangles_t parametric_mesh_t::triangles ( ) const
noexcept

Definition at line 95 of file parametric_mesh.cpp.

◆ vertices()

parametric_mesh_t::vertices_t parametric_mesh_t::vertices ( ) const
noexcept

Definition at line 100 of file parametric_mesh.cpp.


The documentation for this class was generated from the following files: