3 #include <Core/Geometry/deprecated/TopologicalMesh.hpp>
5 #include <OpenMesh/Tools/Subdivider/Uniform/SubdividerT.hh>
18 :
public OpenMesh::Subdivider::Uniform::SubdividerT<deprecated::TopologicalMesh, Scalar>
20 using base = OpenMesh::Subdivider::Uniform::SubdividerT<deprecated::TopologicalMesh, Scalar>;
21 using V_OP = std::pair<Scalar, deprecated::TopologicalMesh::VertexHandle>;
22 using V_OPS = std::pair<deprecated::TopologicalMesh::VertexHandle, std::vector<V_OP>>;
23 using SV_OPS = std::vector<V_OPS>;
24 using P_OP = std::pair<Scalar, deprecated::TopologicalMesh::HalfedgeHandle>;
25 using P_OPS = std::pair<deprecated::TopologicalMesh::HalfedgeHandle, std::vector<P_OP>>;
26 using SP_OPS = std::vector<P_OPS>;
38 const char* name(
void )
const override {
return "CatmullClarkSubdivider"; }
60 void recompute(
const Vector3Array& newCoarseVertices,
61 const Vector3Array& newCoarseNormals,
62 Vector3Array& newSubdivVertices,
63 Vector3Array& newSubdivNormals,
73 const bool _update_points =
true )
override;
80 const deprecated::TopologicalMesh::EdgeHandle& eh,
85 const deprecated::TopologicalMesh::FaceHandle& fh,
92 const deprecated::TopologicalMesh::EdgeHandle& eh,
93 const bool update_points,
98 const deprecated::TopologicalMesh::VertexHandle& vh,
103 OpenMesh::EPropHandleT<Scalar> m_creaseWeights;
106 OpenMesh::VPropHandleT<deprecated::TopologicalMesh::Point> m_vpPos;
109 OpenMesh::EPropHandleT<deprecated::TopologicalMesh::VertexHandle> m_epH;
112 OpenMesh::FPropHandleT<deprecated::TopologicalMesh::VertexHandle> m_fpH;
115 OpenMesh::FPropHandleT<deprecated::TopologicalMesh::Normal> m_normalPropF;
118 std::vector<OpenMesh::FPropHandleT<Scalar>> m_floatPropsF;
119 std::vector<OpenMesh::FPropHandleT<Vector2>> m_vec2PropsF;
120 std::vector<OpenMesh::FPropHandleT<Vector3>> m_vec3PropsF;
121 std::vector<OpenMesh::FPropHandleT<Vector4>> m_vec4PropsF;
124 std::vector<SV_OPS> m_oldVertexOps;
125 std::vector<SV_OPS> m_newFaceVertexOps;
126 std::vector<SV_OPS> m_newEdgeVertexOps;
127 std::vector<SP_OPS> m_newEdgePropOps;
128 std::vector<SP_OPS> m_newFacePropOps;
129 SP_OPS m_triangulationPropOps;
132 OpenMesh::HPropHandleT<deprecated::TopologicalMesh::VertexHandle> m_hV;