52 #ifndef OPENMESH_SUBDIVIDER_UNIFORM_SUDIVIDERT_HH
53 #define OPENMESH_SUBDIVIDER_UNIFORM_SUDIVIDERT_HH
57 #include <OpenMesh/Core/System/config.hh>
58 #include <OpenMesh/Core/Utils/Noncopyable.hh>
59 #if defined(_DEBUG) || defined(DEBUG)
62 # include <OpenMesh/Tools/Utils/MeshCheckerT.hh>
63 # define ASSERT_CONSISTENCY( T, m ) \
64 assert(OpenMesh::Utils::MeshCheckerT<T>(m).check())
66 # define ASSERT_CONSISTENCY( T, m )
72 namespace Subdivider {
86 template <
typename MeshType,
typename RealType=
float>
91 typedef MeshType mesh_t;
92 typedef RealType real_t;
113 virtual const char *name(
void )
const = 0;
121 bool operator () ( MeshType& _m,
size_t _n ,
const bool _update_points =
true)
133 if ( attached_ == &_m )
147 bool operator()(
size_t _n ,
const bool _update_points =
true)
149 return attached_ ?
subdivide( *attached_, _n , _update_points) :
false;
169 virtual bool prepare( MeshType& _m ) = 0;
172 virtual bool subdivide( MeshType& _m,
size_t _n,
const bool _update_points =
true) = 0;
175 virtual bool cleanup( MeshType& _m ) = 0;
189 #endif // OPENMESH_SUBDIVIDER_UNIFORM_SUBDIVIDERT_HH