11 #ifndef __BV_LeafIterator_h__
12 #define __BV_LeafIterator_h__
33 { advanceSubclass(); }
36 { jumpSubclass(leafId); }
41 {
return atEndSubclass(); }
48 {
return getLeafIdSubclass(); }
51 {
return calcBarycenterSubclass(); }
54 {
return isDisabledSubclass(); }
61 { advanceVertexSubclass(); }
63 {
return atEndVertexSubclass(); }
65 { rewindVertexSubclass(); }
68 {
return getVertexSubclass(); }
78 { mySkipDups = flag; setSkipDupVertsSubclass(flag); }
80 {
return mySkipDups; }
84 virtual void advanceSubclass() = 0;
85 virtual void jumpSubclass(
int leafId) = 0;
86 virtual bool atEndSubclass()
const = 0;
87 virtual void rewindSubclass() = 0;
88 virtual int getLeafIdSubclass()
const = 0;
90 virtual UT_Vector3 calcBarycenterSubclass()
const = 0;
91 virtual bool isDisabledSubclass()
const;
93 virtual void advanceVertexSubclass() = 0;
94 virtual bool atEndVertexSubclass()
const = 0;
95 virtual void rewindVertexSubclass() = 0;
96 virtual UT_Vector4 getVertexSubclass()
const = 0;
98 virtual void setSkipDupVertsSubclass(
bool flag) = 0;
void advance()
Advance iterator to next leaf.
bool getSkipDupVerts() const
void advanceVertex()
Get number of vertices bounding current leaf.
UT_Vector4 getVertex() const
Get given bounding vertex of current leaf.
void rewind()
Reset to first leaf.
virtual fpreal getVertexRadius() const
bool isDisabled() const
Test if the current leaf is disabled.
LeafData & operator=(const LeafData &)=delete
void jump(int leafId)
Random access: jump to given leaf id.
void setSkipDupVerts(bool flag)
int getLeafId() const
Get id of current leaf.
UT_Vector3 calcBarycenter() const
Get barycenter of current leaf.