SAGA API
v9.6
|
#include <shapes.h>
Public Member Functions | |
CSG_KDTree_3D (void) | |
virtual | ~CSG_KDTree_3D (void) |
CSG_KDTree_3D (CSG_Shapes *pPoints, int Field=-1, int zField=-1, double zScale=1.) | |
bool | Create (CSG_Shapes *pPoints, int Field=-1, int zField=-1, double zScale=1.) |
CSG_KDTree_3D (CSG_PointCloud *pPoints) | |
bool | Create (CSG_PointCloud *pPoints) |
CSG_KDTree_3D (const CSG_Matrix &Points) | |
bool | Create (const CSG_Matrix &Points) |
CSG_KDTree_3D (const double **Points, size_t nPoints) | |
bool | Create (const double **Points, size_t nPoints) |
virtual bool | Destroy (void) |
virtual double | Get_Point_Value (size_t i) const |
virtual size_t | Get_Nearest_Points (double Coordinate[3], size_t Count, double Radius) |
virtual size_t | Get_Nearest_Points (double Coordinate[3], size_t Count, size_t *Indices, double *Distances) |
virtual size_t | Get_Nearest_Points (double Coordinate[3], size_t Count, double Radius, CSG_Array_sLong &Indices, CSG_Vector &Distances) |
virtual bool | Get_Nearest_Point (double Coordinate[3], size_t &Index, double &Distance) |
virtual bool | Get_Nearest_Point (double Coordinate[3], size_t &Index) |
virtual bool | Get_Nearest_Value (double Coordinate[3], double &Value) |
virtual CSG_Shape * | Get_Nearest_Shape (double Coordinate[3]) |
virtual size_t | Get_Duplicates (double Coordinate[3], CSG_Array_sLong &Indices, CSG_Vector &Distances) |
virtual size_t | Get_Duplicates (double Coordinate[3]) |
virtual size_t | Get_Nearest_Points (double x, double y, double z, size_t Count, double Radius) |
virtual size_t | Get_Nearest_Points (double x, double y, double z, size_t Count, double Radius, CSG_Array_sLong &Indices, CSG_Vector &Distances) |
virtual size_t | Get_Nearest_Points (double x, double y, double z, size_t Count, size_t *Indices, double *Distances) |
virtual bool | Get_Nearest_Point (double x, double y, double z, size_t &Index, double &Distance) |
virtual bool | Get_Nearest_Point (double x, double y, double z, size_t &Index) |
virtual bool | Get_Nearest_Value (double x, double y, double z, double &Value) |
virtual CSG_Shape * | Get_Nearest_Shape (double x, double y, double z) |
virtual size_t | Get_Duplicates (double x, double y, double z, CSG_Array_sLong &Indices, CSG_Vector &Distances) |
virtual size_t | Get_Duplicates (double x, double y, double z) |
Public Member Functions inherited from CSG_KDTree | |
CSG_KDTree (void) | |
virtual | ~CSG_KDTree (void) |
bool | is_Okay (void) const |
size_t | Get_Match_Count (void) const |
size_t | Get_Match_Index (size_t i) const |
double | Get_Match_Distance (size_t i) const |
CSG_Shape * | Get_Match_Shape (size_t i) const |
int | Get_Point_Count (void) const |
double * | Get_Point (int i) const |
double * | Get_Point (size_t i) const |
double * | operator[] (int i) const |
double * | operator[] (size_t i) const |
virtual double | Get_Point_Value (int i) const |
Additional Inherited Members | |
Static Public Member Functions inherited from CSG_KDTree | |
static const char * | Get_Version (void) |
Protected Member Functions inherited from CSG_KDTree | |
void | _On_Construction (void) |
Protected Attributes inherited from CSG_KDTree | |
class CSG_KDTree_Adaptor * | m_pAdaptor |
void * | m_pKDTree |
CSG_Array_sLong | m_Indices |
CSG_Vector | m_Distances |
CSG_Matrix | m_Points |
CSG_KDTree_3D::CSG_KDTree_3D | ( | void | ) |
Definition at line 699 of file kdtree.cpp.
References CSG_KDTree::_On_Construction().
|
virtual |
Definition at line 705 of file kdtree.cpp.
References Destroy().
CSG_KDTree_3D::CSG_KDTree_3D | ( | CSG_Shapes * | pPoints, |
int | Field = -1 , |
||
int | zField = -1 , |
||
double | zScale = 1. |
||
) |
Creates a spatial index for the given points. If 'Field' refers to a valid field, an internal points arrray is created which omits points with no-data entries for the given field. If 'zField' refers to a valid field, its values are taken as coordinate of the 3rd dimension. Else it is expected that the points provide 3 dimensional coordinates (i.e. x-y-z or x-y-z-m).
Definition at line 720 of file kdtree.cpp.
References CSG_KDTree::_On_Construction(), and Create().
CSG_KDTree_3D::CSG_KDTree_3D | ( | CSG_PointCloud * | pPoints | ) |
Definition at line 785 of file kdtree.cpp.
References CSG_KDTree::_On_Construction(), and Create().
CSG_KDTree_3D::CSG_KDTree_3D | ( | const CSG_Matrix & | Points | ) |
Points matrix is expected to provide coordinates ordered in rows, with first, second and third column holding x, y and z coordinates.
Definition at line 815 of file kdtree.cpp.
References CSG_KDTree::_On_Construction(), and Create().
CSG_KDTree_3D::CSG_KDTree_3D | ( | const double ** | Points, |
size_t | nPoints | ||
) |
Points array is expected to provide coordinates ordered in rows, with first, second and third column holding x, y and z coordinates.
Definition at line 838 of file kdtree.cpp.
References CSG_KDTree::_On_Construction(), and Create().
bool CSG_KDTree_3D::Create | ( | const CSG_Matrix & | Points | ) |
Definition at line 822 of file kdtree.cpp.
References Create(), CSG_Matrix::Get_Data(), CSG_Matrix::Get_NCols(), and CSG_Matrix::Get_NRows().
bool CSG_KDTree_3D::Create | ( | const double ** | Points, |
size_t | nPoints | ||
) |
Definition at line 845 of file kdtree.cpp.
References Destroy(), CSG_KDTree::m_pAdaptor, and CSG_KDTree::m_pKDTree.
bool CSG_KDTree_3D::Create | ( | CSG_PointCloud * | pPoints | ) |
Definition at line 792 of file kdtree.cpp.
References Destroy(), CSG_Table::Get_Count(), CSG_KDTree::m_pAdaptor, and CSG_KDTree::m_pKDTree.
bool CSG_KDTree_3D::Create | ( | CSG_Shapes * | pPoints, |
int | Field = -1 , |
||
int | zField = -1 , |
||
double | zScale = 1. |
||
) |
Definition at line 727 of file kdtree.cpp.
References CSG_Table_Record::asDouble(), CSG_Matrix::Create(), Destroy(), CSG_Table::Get_Count(), CSG_Matrix::Get_NRows(), CSG_Shape::Get_Point(), CSG_Shapes::Get_Shape(), CSG_Shape::Get_Z(), CSG_Table_Record::is_NoData(), CSG_KDTree::m_pAdaptor, CSG_KDTree::m_pKDTree, CSG_KDTree::m_Points, CSG_Matrix::Set_Rows(), SSG_Point::x, and SSG_Point::y.
Referenced by Create(), and CSG_KDTree_3D().
|
virtual |
Reimplemented from CSG_KDTree.
Definition at line 863 of file kdtree.cpp.
References CSG_KDTree::Destroy(), and CSG_KDTree::m_pKDTree.
Referenced by Create(), and ~CSG_KDTree_3D().
|
virtual |
Definition at line 1021 of file kdtree.cpp.
References Get_Duplicates(), CSG_KDTree::m_Distances, and CSG_KDTree::m_Indices.
|
virtual |
Definition at line 990 of file kdtree.cpp.
References CSG_Array_sLong::Create(), CSG_Vector::Create(), CSG_Array_sLong::Dec_Array(), and CSG_KDTree::m_pKDTree.
Referenced by Get_Duplicates().
|
virtual |
Definition at line 1067 of file kdtree.cpp.
References Get_Duplicates().
|
virtual |
Definition at line 1062 of file kdtree.cpp.
References Get_Duplicates().
|
virtual |
Definition at line 959 of file kdtree.cpp.
References Get_Nearest_Points().
|
virtual |
Definition at line 953 of file kdtree.cpp.
References Get_Nearest_Points().
Referenced by Get_Nearest_Point(), and Get_Nearest_Shape().
|
virtual |
Definition at line 1047 of file kdtree.cpp.
References Get_Nearest_Point().
|
virtual |
Definition at line 1042 of file kdtree.cpp.
References Get_Nearest_Point().
|
virtual |
Definition at line 881 of file kdtree.cpp.
References CSG_KDTree::m_Distances, and CSG_KDTree::m_Indices.
Referenced by Get_Nearest_Point(), Get_Nearest_Points(), and Get_Nearest_Value().
|
virtual |
Definition at line 887 of file kdtree.cpp.
References CSG_Array_sLong::Create(), CSG_Vector::Create(), CSG_Vector::Get_Data(), CSG_Vector::Get_N(), Get_Nearest_Points(), CSG_KDTree::m_pKDTree, and CSG_Vector::Set_Rows().
|
virtual |
Definition at line 940 of file kdtree.cpp.
References CSG_KDTree::m_pKDTree.
|
virtual |
Definition at line 1027 of file kdtree.cpp.
References Get_Nearest_Points().
|
virtual |
Definition at line 1032 of file kdtree.cpp.
References Get_Nearest_Points().
|
virtual |
Definition at line 1037 of file kdtree.cpp.
References Get_Nearest_Points().
|
virtual |
Definition at line 982 of file kdtree.cpp.
References Get_Nearest_Point(), CSG_Shapes::Get_Shape(), and CSG_KDTree::m_pAdaptor.
Referenced by Get_Nearest_Shape().
|
virtual |
Definition at line 1057 of file kdtree.cpp.
References Get_Nearest_Shape().
|
virtual |
Definition at line 967 of file kdtree.cpp.
References CSG_Matrix::Get_Data(), Get_Nearest_Points(), Get_Point_Value(), and CSG_KDTree::m_Points.
Referenced by Get_Nearest_Value().
|
virtual |
Definition at line 1052 of file kdtree.cpp.
References Get_Nearest_Value().
|
inlinevirtual |