78void* G4KDTree::operator
new(size_t)
84void G4KDTree::operator
delete(
void *aNode)
86 fgAllocator()->FreeSingle((
G4KDTree*) aNode);
127 G4cout <<
"template<typename PointT> G4KDTree<PointT>::Build" <<
G4endl;
132 if(root == 0)
return;
143 for (
size_t n = 0; n < Nnodes; n +=
fDim)
145 for (
size_t dim = 0; dim <
fDim; dim++)
168 std::vector<G4KDNode_Base* > result;
189 rset->Insert(dist_sq, result[j]);
210 const double range_sq =
sqr(range);
G4GLOB_DLL std::ostream G4cout
G4KDNode_Base * PopOutMiddle(size_t dimension)
void Insert(G4KDNode_Base *pos)
void Print(std::ostream &out, int level=0) const
G4KDNode_Base * GetRight()
G4KDNode_Base * Insert(PointT *point)
G4KDNode_Base * GetLeft()
void SetMinMax(const Position &min, const Position &max)
void Extend(const Position &pos)
int __NearestInRange(G4KDNode_Base *node, const Position &pos, const double &range_sq, const double &range, G4KDTreeResult &list, int ordered, G4KDNode_Base *source_node=0)
G4KDTreeResultHandle Nearest(const Position &pos)
void Print(std::ostream &out=G4cout) const
void __NearestToNode(G4KDNode_Base *source_node, G4KDNode_Base *node, const Position &pos, std::vector< G4KDNode_Base * > &result, double *result_dist_sq, HyperRect *fRect, int &nbresult)
G4KDTreeResultHandle NearestInRange(const Position &pos, const double &range)
void __InsertMap(G4KDNode_Base *node)
static G4Allocator< G4KDTree > *& fgAllocator()
void __Clear_Rec(G4KDNode_Base *node)
#define G4ThreadLocalStatic