Static Public Member Functions | Static Private Member Functions | Static Private Attributes | List of all members
lvr2::Tesselator< BaseVecT > Class Template Reference

#include <Tesselator.hpp>

Static Public Member Functions

static void apply (BaseMesh< BaseVecT > &mesh, ClusterBiMap< FaceHandle > &clusters, DenseFaceMap< Normal< typename BaseVecT::CoordType >> &faceNormals, float lineFusionThreshold)
 

Static Private Member Functions

static void addTesselatedFaces (BaseMesh< BaseVecT > &mesh, ClusterBiMap< FaceHandle > &clusters, DenseFaceMap< Normal< typename BaseVecT::CoordType >> &faceNormal, ClusterHandle clusterH)
 
static void CALLBACK beginCallback (GLenum type)
 
static void CALLBACK combineDataCallback (GLdouble coords[3], void *vertex_data[4], GLfloat weight[4], void **outData, void *userData)
 
static void CALLBACK endCallback (void)
 
static void CALLBACK errorCallback (GLenum errno)
 
static void init ()
 
static void CALLBACK vertexCallback (void *data)
 

Static Private Attributes

static std::vector< BaseVecT > m_faces
 
static GLUtesselator * m_tesselator
 
static GLenum m_type
 
static std::vector< BaseVecT > m_vertices
 

Detailed Description

template<typename BaseVecT>
class lvr2::Tesselator< BaseVecT >

Tesslation algorithm, utilizing the OpenGL tesselator to ease the reconstructed mesh. This algorithm is destryoing the mesh correlation between clusters, faces and vertices thus it is currently not suitable to run any algorithms requiring an coherent mesh.

Definition at line 61 of file Tesselator.hpp.

Member Function Documentation

◆ addTesselatedFaces()

template<typename BaseVecT >
static void lvr2::Tesselator< BaseVecT >::addTesselatedFaces ( BaseMesh< BaseVecT > &  mesh,
ClusterBiMap< FaceHandle > &  clusters,
DenseFaceMap< Normal< typename BaseVecT::CoordType >> &  faceNormal,
ClusterHandle  clusterH 
)
staticprivate

Adds the tesslated faces to the current cluster. Avoid any errors while adding duplicated vertices, it first removes all of the faces in the cluster, than removing the cluster itself and eventually creating an new one with the new tesslated faces.

◆ apply()

template<typename BaseVecT >
static void lvr2::Tesselator< BaseVecT >::apply ( BaseMesh< BaseVecT > &  mesh,
ClusterBiMap< FaceHandle > &  clusters,
DenseFaceMap< Normal< typename BaseVecT::CoordType >> &  faceNormals,
float  lineFusionThreshold 
)
static

Retesselates the current mesh cluster by cluster.

◆ beginCallback()

template<typename BaseVecT >
static void CALLBACK lvr2::Tesselator< BaseVecT >::beginCallback ( GLenum  type)
staticprivate

OpenGL callback, which is invoked by glBegin() to indicate the start of an primitiv.

◆ combineDataCallback()

template<typename BaseVecT >
static void CALLBACK lvr2::Tesselator< BaseVecT >::combineDataCallback ( GLdouble  coords[3],
void *  vertex_data[4],
GLfloat  weight[4],
void **  outData,
void *  userData 
)
staticprivate

OpenGL callback, which is called when the tesselator wants to create an new vertex on an intersection. This simply takes the coords and adds it as an new vertex to our interal list.

◆ endCallback()

template<typename BaseVecT >
static void CALLBACK lvr2::Tesselator< BaseVecT >::endCallback ( void  )
staticprivate

OpenGL callback, which is invoked by glEnd() to indicate the end of an primitiv.

◆ errorCallback()

template<typename BaseVecT >
static void CALLBACK lvr2::Tesselator< BaseVecT >::errorCallback ( GLenum  errno)
staticprivate

OpenGL callback, which is called on any error occurring while running the tesslation.

◆ init()

template<typename BaseVecT >
static void lvr2::Tesselator< BaseVecT >::init ( )
staticprivate

Initalizes the tesselator object, deleting the old one if one is found and registering all necessary callbacks.

◆ vertexCallback()

template<typename BaseVecT >
static void CALLBACK lvr2::Tesselator< BaseVecT >::vertexCallback ( void *  data)
staticprivate

OpenGL callback, which is called for every vertex, adding it to our internal list.

Member Data Documentation

◆ m_faces

template<typename BaseVecT >
std::vector<BaseVecT> lvr2::Tesselator< BaseVecT >::m_faces
staticprivate

List of faces to keep track of until the end of the tesselation.

Definition at line 95 of file Tesselator.hpp.

◆ m_tesselator

template<typename BaseVecT >
GLUtesselator* lvr2::Tesselator< BaseVecT >::m_tesselator
staticprivate

The OpenGL tesselation object

Definition at line 80 of file Tesselator.hpp.

◆ m_type

template<typename BaseVecT >
GLenum lvr2::Tesselator< BaseVecT >::m_type
staticprivate

The OpenGL type. This defines how the vertices are tesselated.

Definition at line 85 of file Tesselator.hpp.

◆ m_vertices

template<typename BaseVecT >
std::vector<BaseVecT> lvr2::Tesselator< BaseVecT >::m_vertices
staticprivate

List of vertices to keep track of until the end of the tesselation.

Definition at line 90 of file Tesselator.hpp.


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


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Wed Mar 2 2022 00:37:27