gKit2 light
Loading...
Searching...
No Matches
Node Struct Reference

construction de l'arbre / BVH. More...

Public Member Functions

bool internal () const
int internal_left () const
int internal_right () const
bool leaf () const
int leaf_begin () const
int leaf_end () const
bool internal () const
int internal_left () const
int internal_right () const
bool leaf () const
int leaf_begin () const
int leaf_end () const
bool internal () const
int internal_left () const
int internal_right () const
bool leaf () const
int leaf_begin () const
int leaf_end () const
bool internal () const
int internal_left () const
int internal_right () const
bool leaf () const
int leaf_begin () const
int leaf_end () const

Public Attributes

BBox bounds
int left
int right

Detailed Description

construction de l'arbre / BVH.

Definition at line 132 of file tuto_bvh.cpp.

Member Function Documentation

◆ internal() [1/4]

bool Node::internal ( ) const
inline

Definition at line 138 of file tuto_bvh.cpp.

138{ return right > 0; } // renvoie vrai si le noeud est un noeud interne

◆ internal_left() [1/4]

int Node::internal_left ( ) const
inline

Definition at line 139 of file tuto_bvh.cpp.

139{ assert(internal()); return left; } // renvoie le fils gauche du noeud interne

◆ internal_right() [1/4]

int Node::internal_right ( ) const
inline

Definition at line 140 of file tuto_bvh.cpp.

140{ assert(internal()); return right; } // renvoie le fils droit

◆ leaf() [1/4]

bool Node::leaf ( ) const
inline

Definition at line 142 of file tuto_bvh.cpp.

142{ return right < 0; } // renvoie vrai si le noeud est une feuille

◆ leaf_begin() [1/4]

int Node::leaf_begin ( ) const
inline

Definition at line 143 of file tuto_bvh.cpp.

143{ assert(leaf()); return -left; } // renvoie le premier objet de la feuille

◆ leaf_end() [1/4]

int Node::leaf_end ( ) const
inline

Definition at line 144 of file tuto_bvh.cpp.

144{ assert(leaf()); return -right; } // renvoie le dernier objet

◆ internal() [2/4]

bool Node::internal ( ) const
inline

Definition at line 99 of file tuto_bvh2.cpp.

99{ return right > 0; } // renvoie vrai si le noeud est un noeud interne

◆ internal_left() [2/4]

int Node::internal_left ( ) const
inline

Definition at line 100 of file tuto_bvh2.cpp.

100{ assert(internal()); return left; } // renvoie le fils gauche du noeud interne

◆ internal_right() [2/4]

int Node::internal_right ( ) const
inline

Definition at line 101 of file tuto_bvh2.cpp.

101{ assert(internal()); return right; } // renvoie le fils droit

◆ leaf() [2/4]

bool Node::leaf ( ) const
inline

Definition at line 103 of file tuto_bvh2.cpp.

103{ return right < 0; } // renvoie vrai si le noeud est une feuille

◆ leaf_begin() [2/4]

int Node::leaf_begin ( ) const
inline

Definition at line 104 of file tuto_bvh2.cpp.

104{ assert(leaf()); return -left; } // renvoie le premier objet de la feuille

◆ leaf_end() [2/4]

int Node::leaf_end ( ) const
inline

Definition at line 105 of file tuto_bvh2.cpp.

105{ assert(leaf()); return -right; } // renvoie le dernier objet

◆ internal() [3/4]

bool Node::internal ( ) const
inline

Definition at line 104 of file tuto_bvh2_gltf.cpp.

104{ return right > 0; } // renvoie vrai si le noeud est un noeud interne

◆ internal_left() [3/4]

int Node::internal_left ( ) const
inline

Definition at line 105 of file tuto_bvh2_gltf.cpp.

105{ assert(internal()); return left; } // renvoie le fils gauche du noeud interne

◆ internal_right() [3/4]

int Node::internal_right ( ) const
inline

Definition at line 106 of file tuto_bvh2_gltf.cpp.

106{ assert(internal()); return right; } // renvoie le fils droit

◆ leaf() [3/4]

bool Node::leaf ( ) const
inline

Definition at line 108 of file tuto_bvh2_gltf.cpp.

108{ return right < 0; } // renvoie vrai si le noeud est une feuille

◆ leaf_begin() [3/4]

int Node::leaf_begin ( ) const
inline

Definition at line 109 of file tuto_bvh2_gltf.cpp.

109{ assert(leaf()); return -left; } // renvoie le premier objet de la feuille

◆ leaf_end() [3/4]

int Node::leaf_end ( ) const
inline

Definition at line 110 of file tuto_bvh2_gltf.cpp.

110{ assert(leaf()); return -right; } // renvoie le dernier objet

◆ internal() [4/4]

bool Node::internal ( ) const
inline

Definition at line 104 of file tuto_bvh2_gltf_brdf.cpp.

104{ return right > 0; } // renvoie vrai si le noeud est un noeud interne

◆ internal_left() [4/4]

int Node::internal_left ( ) const
inline

Definition at line 105 of file tuto_bvh2_gltf_brdf.cpp.

105{ assert(internal()); return left; } // renvoie le fils gauche du noeud interne

◆ internal_right() [4/4]

int Node::internal_right ( ) const
inline

Definition at line 106 of file tuto_bvh2_gltf_brdf.cpp.

106{ assert(internal()); return right; } // renvoie le fils droit

◆ leaf() [4/4]

bool Node::leaf ( ) const
inline

Definition at line 108 of file tuto_bvh2_gltf_brdf.cpp.

108{ return right < 0; } // renvoie vrai si le noeud est une feuille

◆ leaf_begin() [4/4]

int Node::leaf_begin ( ) const
inline

Definition at line 109 of file tuto_bvh2_gltf_brdf.cpp.

109{ assert(leaf()); return -left; } // renvoie le premier objet de la feuille

◆ leaf_end() [4/4]

int Node::leaf_end ( ) const
inline

Definition at line 110 of file tuto_bvh2_gltf_brdf.cpp.

110{ assert(leaf()); return -right; } // renvoie le dernier objet

Member Data Documentation

◆ bounds

BBox Node::bounds

Definition at line 134 of file tuto_bvh.cpp.

◆ left

int Node::left

Definition at line 135 of file tuto_bvh.cpp.

◆ right

int Node::right

Definition at line 136 of file tuto_bvh.cpp.


The documentation for this struct was generated from the following files: