Blender  V3.3
Public Member Functions | Public Attributes | Protected Types | Protected Member Functions | Protected Attributes | List of all members
BVHObjectBinning Class Reference

#include <binning.h>

Inheritance diagram for BVHObjectBinning:
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 BoundBoxunaligned_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 BoundBoxbounds () const
 
__forceinline const BoundBoxcent_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 BVHUnalignedunaligned_heuristic_
 
const Transformaligned_space_
 
- Protected Attributes inherited from BVHRange
BoundBox rbounds
 
BoundBox cbounds
 

Detailed Description

Definition at line 24 of file binning.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
protected
Enumerator
MAX_BINS 

Definition at line 58 of file binning.h.

◆ anonymous enum

anonymous enum
protected
Enumerator
LOG_BLOCK_SIZE 

Definition at line 59 of file binning.h.

Constructor & Destructor Documentation

◆ BVHObjectBinning() [1/2]

__forceinline BVHObjectBinning::BVHObjectBinning ( )
inline

Definition at line 26 of file binning.h.

Referenced by split().

◆ BVHObjectBinning() [2/2]

BVHObjectBinning::BVHObjectBinning ( const BVHRange job,
BVHReference prims,
const BVHUnaligned unaligned_heuristic = NULL,
const Transform aligned_space = NULL 
)

Member Function Documentation

◆ blocks() [1/2]

__forceinline float4 BVHObjectBinning::blocks ( const int4 a) const
inlineprotected

Definition at line 78 of file binning.h.

References Freestyle::a, LOG_BLOCK_SIZE, make_float4, and make_int4.

Referenced by BVHObjectBinning().

◆ blocks() [2/2]

__forceinline int BVHObjectBinning::blocks ( size_t  a) const
inlineprotected

Definition at line 84 of file binning.h.

References Freestyle::a, and LOG_BLOCK_SIZE.

◆ get_bin() [1/2]

__forceinline int4 BVHObjectBinning::get_bin ( const BoundBox box) const
inlineprotected

◆ get_bin() [2/2]

__forceinline int4 BVHObjectBinning::get_bin ( const float3 c) const
inlineprotected

Definition at line 72 of file binning.h.

References Freestyle::c, cent_bounds_, make_float3, make_int4, BoundBox::min, and scale.

◆ get_prim_bounds()

__forceinline BoundBox BVHObjectBinning::get_prim_bounds ( const BVHReference prim) const
inlineprotected

◆ split()

void BVHObjectBinning::split ( BVHReference prims,
BVHObjectBinning left_o,
BVHObjectBinning right_o 
) const

◆ unaligned_bounds()

__forceinline const BoundBox& BVHObjectBinning::unaligned_bounds ( )
inline

Definition at line 37 of file binning.h.

References bounds_.

Referenced by BVHBuild::build_node(), and split().

Member Data Documentation

◆ aligned_space_

const Transform* BVHObjectBinning::aligned_space_
protected

Definition at line 56 of file binning.h.

Referenced by BVHObjectBinning(), and get_prim_bounds().

◆ bounds_

BoundBox BVHObjectBinning::bounds_
protected

Definition at line 52 of file binning.h.

Referenced by BVHObjectBinning(), and unaligned_bounds().

◆ cent_bounds_

BoundBox BVHObjectBinning::cent_bounds_
protected

Definition at line 53 of file binning.h.

Referenced by BVHObjectBinning(), and get_bin().

◆ dim

int BVHObjectBinning::dim
protected

Definition at line 46 of file binning.h.

Referenced by BVHObjectBinning(), and split().

◆ leafSAH

float BVHObjectBinning::leafSAH

Definition at line 43 of file binning.h.

Referenced by BVHBuild::build_node(), and BVHObjectBinning().

◆ num_bins

size_t BVHObjectBinning::num_bins
protected

Definition at line 48 of file binning.h.

Referenced by BVHObjectBinning(), and get_bin().

◆ pos

int BVHObjectBinning::pos
protected

Definition at line 47 of file binning.h.

Referenced by BVHObjectBinning(), and split().

◆ scale

float3 BVHObjectBinning::scale
protected

Definition at line 49 of file binning.h.

Referenced by BVHObjectBinning(), and get_bin().

◆ splitSAH

float BVHObjectBinning::splitSAH

Definition at line 42 of file binning.h.

Referenced by BVHBuild::build_node(), and BVHObjectBinning().

◆ unaligned_heuristic_

const BVHUnaligned* BVHObjectBinning::unaligned_heuristic_
protected

Definition at line 55 of file binning.h.

Referenced by get_prim_bounds().


The documentation for this class was generated from the following files: