Polyhedral-net Splines
Loading...
Searching...
No Matches
PatchConstructor.hpp
1/* copyright(c)Jorg Peters [jorg.peters@gmail.com] */
2
3#pragma once
4
5#include <OpenMesh/Core/Mesh/PolyMesh_ArrayKernelT.hh>
6#include "PatchBuilder.hpp"
7
52
53
54typedef OpenMesh::PolyMesh_ArrayKernelT<> MeshType;
55typedef MeshType::VertexHandle VertexHandle;
56typedef MeshType::FaceHandle FaceHandle;
57
66{
67public:
75 virtual bool isSamePatchType(const VertexHandle&, MeshType& a_Mesh, bool check_marked = false) { return false; };
76
84 virtual bool isSamePatchType(const FaceHandle&, MeshType& a_Mesh, bool check_marked = false) { return false; };
85
94 virtual PatchBuilder getPatchBuilder(const VertexHandle&, MeshType& a_Mesh, bool mark_gathered = false){throw std::runtime_error("getPatchBuilder for VertexHandle not implemented");};
95
104 virtual PatchBuilder getPatchBuilder(const FaceHandle&, MeshType& a_Mesh, bool mark_gathered = false){throw std::runtime_error("getPatchBuilder for FaceHandle not implemented");};
105
113 virtual std::string getGroupName() const = 0;
114private:
115
116};
A builder class for constructing Bézier patches from a mesh.
Definition PatchBuilder.hpp:28
Abstract base class for patch constructors.
Definition PatchConstructor.hpp:66
virtual PatchBuilder getPatchBuilder(const FaceHandle &, MeshType &a_Mesh, bool mark_gathered=false)
Constructs a PatchBuilder for the patch type at the given face.
Definition PatchConstructor.hpp:104
virtual PatchBuilder getPatchBuilder(const VertexHandle &, MeshType &a_Mesh, bool mark_gathered=false)
Constructs a PatchBuilder for the patch type at the given vertex.
Definition PatchConstructor.hpp:94
virtual std::string getGroupName() const =0
Returns the name of the patch group this constructor handles.
virtual bool isSamePatchType(const FaceHandle &, MeshType &a_Mesh, bool check_marked=false)
Given a face, checks wither the face and the neighborhood arund the face of this patch type.
Definition PatchConstructor.hpp:84
virtual bool isSamePatchType(const VertexHandle &, MeshType &a_Mesh, bool check_marked=false)
Given a vertex, checks wither the vertex and the neighborhood arund the vertex of this patch type.
Definition PatchConstructor.hpp:75