59 #ifndef OPENMESH_SUBDIVIDER_UNIFORM_COMPOSITESQRT3T_HH 60 #define OPENMESH_SUBDIVIDER_UNIFORM_COMPOSITESQRT3T_HH 65 #include "Composite/CompositeT.hh" 66 #include "Composite/CompositeTraits.hh" 72 namespace Subdivider {
80 template <
typename MeshType,
typename RealType=
float>
95 const char *
name()
const {
return "Uniform Composite Sqrt3"; }
104 Inherited::FVc(coeffs_);
116 FVCoeff() : Coeff() { init(50); }
118 void init(
size_t _max_valence)
120 weights_.resize(_max_valence);
121 std::generate(weights_.begin(),
125 double operator()(
size_t _valence) {
return weights_[_valence]; }
133 double operator()(
void)
135 return 2.0/3.0 * (cos(2.0*M_PI/val_++)+1.0);
140 std::vector<double> weights_;
152 #endif // OPENMESH_SUBDIVIDER_UNIFORM_COMPOSITESQRT3T_HH defined
Abstract base class for coefficient functions.
const char * name() const
Return name of subdivision algorithm.