|
Blender
V2.93
|
#include <bvh_binning.h>
Inherits BVHRange.
Public Member Functions | |
| __forceinline | BVHObjectBinning () |
| BVHObjectBinning (const BVHRange &job, BVHReference *prims, const BVHUnaligned *unaligned_heuristic=NULL, const Transform *aligned_space=NULL) | |
| void | split (BVHReference *prims, BVHObjectBinning &left_o, BVHObjectBinning &right_o) const |
| __forceinline const BoundBox & | unaligned_bounds () |
Public Member Functions inherited from BVHRange | |
| __forceinline | BVHRange () |
| __forceinline | BVHRange (const BoundBox &bounds_, int start_, int size_) |
| __forceinline | BVHRange (const BoundBox &bounds_, const BoundBox &cbounds_, int start_, int size_) |
| __forceinline void | set_start (int start_) |
| __forceinline const BoundBox & | bounds () const |
| __forceinline const BoundBox & | cent_bounds () const |
| __forceinline int | start () const |
| __forceinline int | size () const |
| __forceinline int | end () const |
Public Attributes | |
| float | splitSAH |
| float | leafSAH |
Protected Types | |
| enum | { MAX_BINS = 32 } |
| enum | { LOG_BLOCK_SIZE = 2 } |
Protected Member Functions | |
| __forceinline int4 | get_bin (const BoundBox &box) const |
| __forceinline int4 | get_bin (const float3 &c) const |
| __forceinline float4 | blocks (const int4 &a) const |
| __forceinline int | blocks (size_t a) const |
| __forceinline BoundBox | get_prim_bounds (const BVHReference &prim) const |
Protected Attributes | |
| int | dim |
| int | pos |
| size_t | num_bins |
| float3 | scale |
| BoundBox | bounds_ |
| BoundBox | cent_bounds_ |
| const BVHUnaligned * | unaligned_heuristic_ |
| const Transform * | aligned_space_ |
Protected Attributes inherited from BVHRange | |
| BoundBox | rbounds |
| BoundBox | cbounds |
Definition at line 37 of file bvh_binning.h.
|
protected |
| Enumerator | |
|---|---|
| MAX_BINS | |
Definition at line 71 of file bvh_binning.h.
|
protected |
| Enumerator | |
|---|---|
| LOG_BLOCK_SIZE | |
Definition at line 72 of file bvh_binning.h.
|
inline |
Definition at line 39 of file bvh_binning.h.
Referenced by split().
| BVHObjectBinning::BVHObjectBinning | ( | const BVHRange & | job, |
| BVHReference * | prims, | ||
| const BVHUnaligned * | unaligned_heuristic = NULL, |
||
| const Transform * | aligned_space = NULL |
||
| ) |
Definition at line 72 of file bvh_binning.cpp.
References aligned_space_, blocks(), BVHRange::bounds(), bounds_, BVHRange::cent_bounds(), cent_bounds_, BVHUnaligned::compute_aligned_boundbox(), count, dim, BoundBox::empty, extract< 0 >(), float3_to_float4(), get_best_dimension(), get_bin(), get_prim_bounds(), BoundBox::grow(), BoundBox::half_area(), leafSAH, make_float3, make_float4, make_int4, mask(), MAX_BINS, merge(), min, NULL, num_bins, pos, prefetch_L2(), rcp, scale, select(), BVHRange::size(), BoundBox::size(), splitSAH, and BVHRange::start().
|
inlineprotected |
Definition at line 91 of file bvh_binning.h.
References Freestyle::a, LOG_BLOCK_SIZE, make_float4, and make_int4.
Referenced by BVHObjectBinning().
|
inlineprotected |
Definition at line 97 of file bvh_binning.h.
References Freestyle::a, and LOG_BLOCK_SIZE.
|
inlineprotected |
Definition at line 75 of file bvh_binning.h.
References Freestyle::a, cent_bounds_, BoundBox::center2(), clamp(), make_float3, make_int4, BoundBox::min, num_bins, and scale.
Referenced by BVHObjectBinning(), and split().
|
inlineprotected |
Definition at line 85 of file bvh_binning.h.
References Freestyle::c, cent_bounds_, make_float3, make_int4, BoundBox::min, and scale.
|
inlineprotected |
Definition at line 102 of file bvh_binning.h.
References aligned_space_, BVHReference::bounds(), BVHUnaligned::compute_aligned_prim_boundbox(), NULL, and unaligned_heuristic_.
Referenced by BVHObjectBinning(), and split().
| void BVHObjectBinning::split | ( | BVHReference * | prims, |
| BVHObjectBinning & | left_o, | ||
| BVHObjectBinning & | right_o | ||
| ) | const |
Definition at line 229 of file bvh_binning.cpp.
References BVHReference::bounds(), BVHRange::bounds(), BVHObjectBinning(), BVHRange::BVHRange(), center, BoundBox::center2(), dim, BoundBox::empty, get_bin(), get_prim_bounds(), BoundBox::grow(), l, N, pos, prefetch_L2(), r, BVHRange::size(), BVHRange::start(), swap(), and unaligned_bounds().
Referenced by BVHBuild::build_node().
|
inline |
Definition at line 50 of file bvh_binning.h.
References bounds_.
Referenced by BVHBuild::build_node(), and split().
|
protected |
Definition at line 69 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and get_prim_bounds().
|
protected |
Definition at line 65 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and unaligned_bounds().
|
protected |
Definition at line 66 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and get_bin().
|
protected |
Definition at line 59 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and split().
| float BVHObjectBinning::leafSAH |
Definition at line 56 of file bvh_binning.h.
Referenced by BVHBuild::build_node(), and BVHObjectBinning().
|
protected |
Definition at line 61 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and get_bin().
|
protected |
Definition at line 60 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and split().
|
protected |
Definition at line 62 of file bvh_binning.h.
Referenced by BVHObjectBinning(), and get_bin().
| float BVHObjectBinning::splitSAH |
Definition at line 55 of file bvh_binning.h.
Referenced by BVHBuild::build_node(), and BVHObjectBinning().
|
protected |
Definition at line 68 of file bvh_binning.h.
Referenced by get_prim_bounds().