ug4
|
A singleton that stores all rules for a piecewise-loop subdivision surface. More...
#include <subdivision_rules_piecewise_loop.h>
Classes | |
struct | NeighborInfo |
Public Member Functions | |
number | get_beta (size_t valency) const |
returns beta as it is used in the subdivision masks. More... | |
vector3 | proj_crease_weights () const |
number | proj_inner_center_weight (size_t valence) const |
void | proj_inner_crease_nbr_weights (number ¢erWgtOut, number *nbrWgtsOut, NeighborInfo *nbrInfos, size_t numNbrs) const |
number | proj_inner_nbr_weight (size_t valence) const |
vector3 | ref_even_crease_weights () const |
returns weights for center, nbr1 and nbr2. More... | |
number | ref_even_inner_center_weight (size_t valence) const |
number | ref_even_inner_nbr_weight (size_t valence) const |
vector2 | ref_odd_crease_weights () const |
vector4 | ref_odd_inner_weights () const |
vector4 | ref_odd_inner_weights (size_t creaseValence) const |
weights of an odd vertex on an inner edge that is connected to a crease. More... | |
Static Public Member Functions | |
static SubdivRules_PLoop & | inst () |
returns the only instance to this singleton. More... | |
Private Member Functions | |
number | calculate_beta (size_t valency) const |
calculates beta as it is used in the subdivision masks. More... | |
size_t | next_ind (size_t ind, size_t numInds) const |
returns the next index in a cyclic index set More... | |
SubdivRules_PLoop & | operator= (const SubdivRules_PLoop &src) |
private assignment operator prohibits assignment. More... | |
size_t | prev_ind (size_t ind, size_t numInds) const |
returns the previous index in a cyclic index set More... | |
SubdivRules_PLoop () | |
private constructor prohibits multiple instantiation. More... | |
SubdivRules_PLoop (const SubdivRules_PLoop &src) | |
private copy constructor prohibits copy-construction. More... | |
Private Attributes | |
std::vector< number > | m_betas |
A singleton that stores all rules for a piecewise-loop subdivision surface.
|
private |
private constructor prohibits multiple instantiation.
|
private |
private copy constructor prohibits copy-construction.
|
private |
calculates beta as it is used in the subdivision masks.
References ug::PI.
number ug::SubdivRules_PLoop::get_beta | ( | size_t | valency | ) | const |
returns beta as it is used in the subdivision masks.
performs a lookup if the valency is small enough. calculates a fresh beta else.
Referenced by proj_inner_center_weight(), proj_inner_nbr_weight(), ref_even_inner_center_weight(), and ref_even_inner_nbr_weight().
|
inlinestatic |
returns the only instance to this singleton.
Referenced by ug::CalculateSmoothCreaseManifoldPosInParentLevelLoopScheme(), ug::CalculateSmoothManifoldPosInParentLevelLoopScheme(), ug::ProjectToLimitPLoop(), and ug::ProjectToLimitSubdivBoundary().
|
inlineprivate |
returns the next index in a cyclic index set
Referenced by proj_inner_crease_nbr_weights().
|
private |
private assignment operator prohibits assignment.
|
inlineprivate |
returns the previous index in a cyclic index set
Referenced by proj_inner_crease_nbr_weights().
|
inline |
Referenced by ug::ProjectToLimitPLoop(), and ug::ProjectToLimitSubdivBoundary().
|
inline |
References get_beta().
Referenced by proj_inner_crease_nbr_weights(), and ug::ProjectToLimitPLoop().
|
inline |
nbrInfos have to be specified in clockwise or counter-clockwise order.
References ug::SubdivRules_PLoop::NeighborInfo::creaseValence, next_ind(), prev_ind(), proj_inner_center_weight(), proj_inner_nbr_weight(), ref_even_inner_center_weight(), ref_even_inner_nbr_weight(), and ref_odd_inner_weights().
Referenced by ug::ProjectToLimitPLoop().
|
inline |
References get_beta().
Referenced by proj_inner_crease_nbr_weights(), and ug::ProjectToLimitPLoop().
|
inline |
returns weights for center, nbr1 and nbr2.
Referenced by ug::SubdivisionProjector::refinement_begins().
|
inline |
|
inline |
|
inline |
Referenced by ug::SubdivisionProjector::new_vertex().
|
inline |
Referenced by ug::SubdivisionProjector::new_vertex(), proj_inner_crease_nbr_weights(), and ref_odd_inner_weights().
|
inline |
weights of an odd vertex on an inner edge that is connected to a crease.
The weight for the vertex on the crease is in v.x(), the inner edge vertex in v.y() and the two indirectly connected vertex weights are in v.z() and v.w. creaseValence specifies the number of associated edges of the crease vertex.
Rules are taken from: "Piecewise Smooth Subdivision Surfaces with Normal Control", H. Biermann, Adi Levin, Denis Zorin.
References ug::PI, and ref_odd_inner_weights().
|
private |