Template Class TextureFinalizer
Defined in File FinalizeAlgorithms.hpp
Class Documentation
-
template<typename BaseVecT>
class TextureFinalizer Algorithm that converts a BaseMesh into a MeshBuffer while destroying the original graph structure. This means that duplicate vertices will be added to the mesh buffer so that textures can be generated.
Public Functions
-
TextureFinalizer(const ClusterBiMap<FaceHandle> &cluster)
Constructor for the finalizer
- Parameters:
cluster – a map which maps all faces to clusters and vice versa
-
void setVertexNormals(const VertexMap<Normal<typename BaseVecT::CoordType>> &normals)
Sets vertex normals for the apply method. This has to be done before apply is called.
- Parameters:
normals – normals for all vertices in the mesh which will be passed to apply
-
void setClusterColors(const ClusterMap<RGB8Color> &colors)
Sets color data for all clusters for the apply method. This has to be done before apply is called.
- Parameters:
colors – color data for all clusters in the mesh which will be passed to apply
-
void setVertexColors(const VertexMap<RGB8Color> &vertexColors)
Sets vertex colors for the apply method. This has to be done before apply is called.
- Parameters:
vertexColors – color values for all vertices in the mesh which will be passed to apply
-
void setMaterializerResult(const MaterializerResult<BaseVecT> &materializerResult)
Sets the materializer result for the apply method. This has to be done before apply is called.
- Parameters:
materializerResult – the result of the materializer that was run on the mesh which will be passed to apply
-
MeshBufferPtr apply(const BaseMesh<BaseVecT> &mesh)
Converts the given BaseMesh into a MeshBuffer and adds further data (e.g. colors, normals) if set
- Parameters:
mesh – the mesh to convert
- Returns:
the resulting mesh buffer
-
TextureFinalizer(const ClusterBiMap<FaceHandle> &cluster)