diff options
author | Andre Susano Pinto <andresusanopinto@gmail.com> | 2009-07-07 23:07:53 +0400 |
---|---|---|
committer | Andre Susano Pinto <andresusanopinto@gmail.com> | 2009-07-07 23:07:53 +0400 |
commit | 5b75ea38ff034d40a67b331b161d0ce870848ebb (patch) | |
tree | 40ff5b604cebdf4454580739322a581e19b23bab /source/blender/render/intern/include | |
parent | 08fa7862510e755b9112a64754ca4401138d957b (diff) |
made rtbuild object_heuristic_spliter faster
I think its something like:
old was: 4*nlogn + 3*(n*6)
new is: (2*nlogn + 3*(n*6)) * f, with f<1
Still missing changing the sorting function to an introsort instead of qsort
Other options like bucketing sort may be worth trying (for very large trees)
Diffstat (limited to 'source/blender/render/intern/include')
-rw-r--r-- | source/blender/render/intern/include/rayobject_rtbuild.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/render/intern/include/rayobject_rtbuild.h b/source/blender/render/intern/include/rayobject_rtbuild.h index 0ead47eefca..f27005a2fa7 100644 --- a/source/blender/render/intern/include/rayobject_rtbuild.h +++ b/source/blender/render/intern/include/rayobject_rtbuild.h @@ -52,6 +52,8 @@ typedef struct RTBuilder /* child partitions calculated during splitting */ int child_offset[RTBUILD_MAX_CHILDS+1]; + + int child_sorted_axis; /* -1 if not sorted */ } RTBuilder; |