I noticed that you have the setting for R-star: recreate_after, which is the threshold of moved entities above which we recreate the whole tree.
I was wondering why this threshold is only applied to existing entities that moved.
I can see here (https://github.com/laundmo/bevy-spatial/blob/main/src/spatial_access.rs#L106) that for added entities the threshold is not used, only the total size of the tree is used.
Shouldn't the threshold be used for any case where we update the tree with add_point ? (i.e. the sum of added + moved entities)?
We have the threshold because calling 100x add_point can be slower than re-creating the tree from scratch, right? In your experience, what is a good value for this parameter?
I noticed that you have the setting for R-star:
recreate_after
, which is the threshold ofmoved
entities above which we recreate the whole tree. I was wondering why this threshold is only applied to existing entities that moved. I can see here (https://github.com/laundmo/bevy-spatial/blob/main/src/spatial_access.rs#L106) that for added entities the threshold is not used, only the total size of the tree is used.Shouldn't the threshold be used for any case where we update the tree with
add_point
? (i.e. the sum of added + moved entities)?We have the threshold because calling 100x
add_point
can be slower than re-creating the tree from scratch, right? In your experience, what is a good value for this parameter?