55 #ifndef OPENMESH_VDPROGMESH_VHIERARCHYNODE_HH 56 #define OPENMESH_VDPROGMESH_VHIERARCHYNODE_HH 64 #include <OpenMesh/Core/Geometry/VectorT.hh> 65 #include <OpenMesh/Core/Mesh/Handles.hh> 66 #include <OpenMesh/Tools/VDPM/VHierarchyNodeIndex.hh> 99 VHierarchyNode() :radius_(0.0f), sin_square_(0.0f),mue_square_(0.0f), sigma_square_(0.0f) { }
103 {
return (parent_handle_.is_valid() ==
false) ?
true :
false; }
107 {
return (lchild_handle_.is_valid() ==
false) ?
true :
false; }
120 { parent_handle_ = _parent_handle; }
123 { lchild_handle_ = _lchild_handle; }
126 float radius()
const {
return radius_; }
128 float sin_square()
const {
return sin_square_; }
129 float mue_square()
const {
return mue_square_; }
130 float sigma_square()
const {
return sigma_square_; }
133 void set_radius(
float _radius) { radius_ = _radius; }
136 void set_sin_square(
float _sin_square) { sin_square_ = _sin_square; }
137 void set_mue_square(
float _mue_square) { mue_square_ = _mue_square; }
138 void set_sigma_square(
float _sigma_square) { sigma_square_ = _sigma_square; }
140 void set_semi_angle(
float _semi_angle)
141 {
float f=sinf(_semi_angle); sin_square_ = f*f; }
143 void set_mue(
float _mue) { mue_square_ = _mue * _mue; }
144 void set_sigma(
float _sigma) { sigma_square_ = _sigma * _sigma; }
148 {
return fund_cut_node_index_[0]; }
151 {
return fund_cut_node_index_[1]; }
154 {
return node_index_; }
160 { node_index_ = _node_index; }
163 { fund_cut_node_index_[0] = _node_index; }
166 { fund_cut_node_index_[1] = _node_index; }
198 #endif // OPENMESH_VDPROGMESH_VHIERARCHYNODE_HH defined VHierarchyNodeHandle parent_handle()
Returns parent handle.
Definition: VHierarchyNode.hh:110
VHierarchyNodeHandle lchild_handle()
Returns handle to left child.
Definition: VHierarchyNode.hh:113
Contains all the mesh ingredients like the polygonal mesh, the triangle mesh, different mesh kernels ...
Definition: MeshItems.hh:64
VHierarchyNodeHandle rchild_handle()
Returns handle to right child.
Definition: VHierarchyNode.hh:116
Vertex hierarchy node.
Definition: VHierarchyNode.hh:95
std::vector< VHierarchyNode > VHierarchyNodeContainer
Container for vertex hierarchy nodes.
Definition: VHierarchyNode.hh:185
bool is_root() const
Returns true, if node is root else false.
Definition: VHierarchyNode.hh:102
Handle for vertex hierarchy nodes.
Definition: VHierarchyNode.hh:82
std::vector< VHierarchyNodeHandle > VHierarchyNodeHandleContainer
Container for vertex hierarchy node handles.
Definition: VHierarchyNode.hh:188
Index of vertex hierarchy node.
Definition: VHierarchyNodeIndex.hh:78
Handle for a vertex entity.
Definition: Handles.hh:125
Base class for all handle types.
Definition: Handles.hh:67
bool is_leaf() const
Returns true, if node is leaf else false.
Definition: VHierarchyNode.hh:106
std::list< VHierarchyNodeHandle > VHierarchyNodeHandleList
Container for vertex hierarchy node handles.
Definition: VHierarchyNode.hh:191