diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-06-16 06:37:21 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-06-17 01:05:58 +0300 |
commit | e85635b8825f9ca52a43408b58c5f66c4e3742e6 (patch) | |
tree | c14178aa0b479f3921d26fb980d1f15b8c0faa89 /source/blender/blenlib/intern/BLI_kdopbvh.c | |
parent | 40a8c4908818bdf1c4628a389803a9a26e2d68f1 (diff) |
Cleanup: comment spelling
Diffstat (limited to 'source/blender/blenlib/intern/BLI_kdopbvh.c')
-rw-r--r-- | source/blender/blenlib/intern/BLI_kdopbvh.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/source/blender/blenlib/intern/BLI_kdopbvh.c b/source/blender/blenlib/intern/BLI_kdopbvh.c index 98e8a5ee425..f43f55a352b 100644 --- a/source/blender/blenlib/intern/BLI_kdopbvh.c +++ b/source/blender/blenlib/intern/BLI_kdopbvh.c @@ -210,8 +210,8 @@ MINLINE axis_t max_axis(axis_t a, axis_t b) #endif /** - * Introsort - * with permission deriven from the following Java code: + * Intro-sort + * with permission deriving from the following Java code: * http://ralphunden.net/content/tutorials/a-guide-to-introsort/ * and he derived it from the SUN STL */ @@ -603,7 +603,9 @@ static void build_implicit_tree_helper(const BVHTree *tree, BVHBuildHelper *data data->remain_leafs = remain + nnodes; } -// return the min index of all the leafs archivable with the given branch +/** + * Return the min index of all the leafs achievable with the given branch. + */ static int implicit_leafs_index(const BVHBuildHelper *data, const int depth, const int child_index) { int min_leaf_index = child_index * data->leafs_per_child[depth - 1]; @@ -623,14 +625,14 @@ static int implicit_leafs_index(const BVHBuildHelper *data, const int depth, con * Generalized implicit tree build * * An implicit tree is a tree where its structure is implied, - * thus there is no need to store child pointers or indexs. + * thus there is no need to store child pointers or indexes. * Its possible to find the position of the child or the parent with simple maths - * (multiplication and adittion). + * (multiplication and addition). * This type of tree is for example used on heaps.. - * where node N has its childs at indexs N*2 and N*2+1. + * where node N has its child at indices N*2 and N*2+1. * - * Although in this case the tree type is general.. and not know until runtime. - * tree_type stands for the maximum number of childs that a tree node can have. + * Although in this case the tree type is general.. and not know until run-time. + * tree_type stands for the maximum number of children that a tree node can have. * All tree types >= 2 are supported. * * Advantages of the used trees include: @@ -1792,7 +1794,7 @@ void BLI_bvhtree_ray_cast_all(BVHTree *tree, /* -------------------------------------------------------------------- */ /** \name BLI_bvhtree_range_query * - * Allocs and fills an array with the indexs of node that are on the given spherical range + * Allocates and fills an array with the indices of node that are on the given spherical range * (center, radius). * Returns the size of the array. * |