55template <
typename Po
intT>
94 template <
typename Po
intT>
99 template <
typename Po
intT>
102 template <
typename Po
intT>
109 template <
typename Position>
120 template <
typename Position>
124 void*
operator new(std::size_t);
125 void operator delete(
void*);
138 template <
typename Position>
139 void SetMinMax(
const Position& min,
const Position& max)
160 for(std::size_t i = 0; i <
fDim; ++i)
167 template <
typename Position>
183 template <
typename Position>
192 result +=
sqr(
fMin[i] - pos[i]);
194 else if(pos[i] >
fMax[i])
196 result +=
sqr(
fMax[i] - pos[i]);
199 if(result >= *bestmatch){
219 if (
this == &rhs)
return *
this;
228 template <
typename Position>
234 template <
typename Position>
239 template <
typename Position>
241 const Position& pos, std::vector<G4KDNode_Base*>& result,
254#include "G4KDTree.icc"
void InactiveNode(G4KDNode_Base *)
void Free(G4KDNode_Base *&)
G4GLOB_DLL std::ostream G4cout
HyperRect(const HyperRect &rect)
void SetMinMax(const Position &min, const Position &max)
void Extend(const Position &pos)
G4bool CompareDistSqr(const Position &pos, const G4double *bestmatch)
HyperRect(std::size_t dim)
std::size_t GetDim() const
void __NearestToNode(G4KDNode_Base *source_node, G4KDNode_Base *node, const Position &pos, std::vector< G4KDNode_Base * > &result, G4double *result_dist_sq, HyperRect *fRect, G4int &nbresult)
G4KDNode_Base * Insert(PointT *pos)
G4KDTreeResultHandle Nearest(const Position &pos)
void NoticeNodeDeactivation()
G4KDNode_Base * Insert(const PointT &pos)
G4int __NearestInRange(G4KDNode_Base *node, const Position &pos, const G4double &range_sq, const G4double &range, G4KDTreeResult &list, G4int ordered, G4KDNode_Base *source_node=nullptr)
void Print(std::ostream &out=G4cout) const
G4KDNode_Base * GetRoot()
G4KDTreeResultHandle NearestInRange(const Position &pos, const G4double &range)
void __InsertMap(G4KDNode_Base *node)
static G4Allocator< G4KDTree > *& fgAllocator()
void __NearestToPosition(G4KDNode_Base *node, const Position &pos, G4KDNode_Base *&result, G4double *result_dist_sq, HyperRect *fRect)
G4KDNode_Base * InsertMap(PointT *pos)
void __Clear_Rec(G4KDNode_Base *node)