tinypbrt 1.1.1
pbrt-v4 scene file parser for C11 with a header-only C++20 wrapper
Loading...
Searching...
No Matches
Accelerator

Data Structures

struct  tpbrt::accelerator_bvh_params
 C++ wrapper for tpbrt_accelerator_bvh_params_t. More...
 
struct  tpbrt::accelerator_kd_tree_params
 C++ wrapper for tpbrt_accelerator_kd_tree_params_t. More...
 
struct  tpbrt::accelerator
 C++ wrapper for tpbrt_accelerator_t. More...
 

Enumerations

enum class  tpbrt::accelerator_type : uchar_t { tpbrt::accelerator_type::BVH = TPBRT_ACCELERATOR_TYPE_BVH , tpbrt::accelerator_type::KD_TREE = TPBRT_ACCELERATOR_TYPE_KD_TREE , tpbrt::accelerator_type::MAX_NUM = TPBRT_ACCELERATOR_TYPE_MAX_NUM }
 Used to declare accelerator type. More...
 
enum class  tpbrt::accelerator_bvh_split_method : uchar_t {
  tpbrt::accelerator_bvh_split_method::SAH = TPBRT_ACCELERATOR_BVH_SPLIT_METHOD_SAH , tpbrt::accelerator_bvh_split_method::MIDDLE = TPBRT_ACCELERATOR_BVH_SPLIT_METHOD_MIDDLE , tpbrt::accelerator_bvh_split_method::EQUAL = TPBRT_ACCELERATOR_BVH_SPLIT_METHOD_EQUAL , tpbrt::accelerator_bvh_split_method::HLBVH = TPBRT_ACCELERATOR_BVH_SPLIT_METHOD_HLBVH ,
  tpbrt::accelerator_bvh_split_method::MAX_NUM = TPBRT_ACCELERATOR_BVH_SPLIT_METHOD_MAX_NUM
}
 Used to declare BVH split method. More...
 

Functions

constexpr std::string_view tpbrt::to_string (const accelerator_type type) noexcept
 Converts accelerator_type enum value to string.
 
constexpr std::string_view tpbrt::to_string (const accelerator_bvh_split_method method) noexcept
 Converts accelerator_bvh_split_method enum value to string.
 

Detailed Description

Enumeration Type Documentation

◆ accelerator_type

enum class tpbrt::accelerator_type : uchar_t
strong

Used to declare accelerator type.

Enumerator
BVH 

BVH acceleration.

KD_TREE 

KD Tree acceleration.

MAX_NUM 

Count of available accelerator types.

◆ accelerator_bvh_split_method

Used to declare BVH split method.

Enumerator
SAH 

SAH split method. Denotes the surface area heuristic.

MIDDLE 

Middle split method. Splits each node at its midpoint along the split axis.

EQUAL 

Equal split method. Splits the current group of primitives into two equal-sized sets.

HLBVH 

HLBVH split method. Selects the HLBVH algorithm, which parallelizes well.

MAX_NUM 

Count of available BVH split methods.

Function Documentation

◆ to_string() [1/2]

constexpr std::string_view tpbrt::to_string ( const accelerator_type  type)
constexprnoexcept

Converts accelerator_type enum value to string.

Parameters
typeAccelerator type.
Returns
String value of accelerator type.
Examples
examples/cpp/materials/main.cpp, examples/cpp/quickstart/main.cpp, and examples/cpp/scene_info/main.cpp.

◆ to_string() [2/2]

constexpr std::string_view tpbrt::to_string ( const accelerator_bvh_split_method  method)
constexprnoexcept

Converts accelerator_bvh_split_method enum value to string.

Parameters
methodAccelerator bvh split method.
Returns
String value of accelerator bvh split method.