Top | ![]() |
![]() |
![]() |
![]() |
This object can be used to find nodes based on coordinates in a linear scaling complexity.
VisuNodeFinder *
visu_node_finder_new (VisuData *data
);
Creates a new VisuNodeFinder to look for node from coordinates.
Since: 3.8
VisuData *
visu_node_finder_getData (VisuNodeFinder *finder
);
Get the VisuData object the finder
is working on.
Since: 3.8
gint visu_node_finder_lookup (VisuNodeFinder *finder
,const gfloat at[3]
,gfloat tol
);
Giving the cartesian coordinates at
, this method lookup for the closest
VisuNode within a radius of tol
.
the id of the closest node to at
(within a maximum radius
of tol
). If none is found, returns -1.
Since: 3.8
void visu_node_finder_lookupArray (VisuNodeFinder *finder
,gint *ids
,const gfloat *at
,guint np
,gfloat tol
);
Apply visu_node_finder_lookup()
on the array at
. It's used mainly
for bindings.
finder |
a VisuNodeFinder object. |
|
ids |
an allocated array of size |
[type gint64] |
at |
an allocated array of size 3 * |
[type gint64] |
np |
the number of coordinates to be tested. |
|
tol |
a radius to find the nodes in. |
Since: 3.8