tinypbrt 1.1.1
pbrt-v4 scene file parser for C11 with a header-only C++20 wrapper
Loading...
Searching...
No Matches
tpbrt::texture_handle Struct Reference

C++ wrapper for tpbrt_texture_handle_t. More...

#include <tinypbrt/detail/cpp/texture.hpp>

Public Member Functions

constexpr texture_handle_value_type value_type () const noexcept
 Returns value_type value.
 
constexpr bool_t is_texture_idx () const noexcept
 Returns true if type is texture_idx.
 
constexpr bool_t is_spectrum () const noexcept
 Returns true if type is spectrum.
 
constexpr std::optional< texture_idx_t > as_texture_idx () const noexcept
 Returns texture handle value as texture_idx.
 
constexpr std::optional< spectrum > as_spectrum () const noexcept
 Returns texture handle value as spectrum.
 
constexpr variant_type to_variant () const noexcept
 Conversion to variant.
 
constexpr auto reflect () const noexcept
 Conversion to tuple.
 

Detailed Description

Member Function Documentation

◆ value_type()

constexpr texture_handle_value_type tpbrt::texture_handle::value_type ( ) const
inlineconstexprnoexcept

Returns value_type value.

◆ is_texture_idx()

constexpr bool_t tpbrt::texture_handle::is_texture_idx ( ) const
inlineconstexprnoexcept

Returns true if type is texture_idx.

◆ is_spectrum()

constexpr bool_t tpbrt::texture_handle::is_spectrum ( ) const
inlineconstexprnoexcept

Returns true if type is spectrum.

◆ as_texture_idx()

constexpr std::optional< texture_idx_t > tpbrt::texture_handle::as_texture_idx ( ) const
inlineconstexprnoexcept

Returns texture handle value as texture_idx.

◆ as_spectrum()

constexpr std::optional< spectrum > tpbrt::texture_handle::as_spectrum ( ) const
inlineconstexprnoexcept

Returns texture handle value as spectrum.

Examples
examples/cpp/materials/main.cpp.

◆ to_variant()

constexpr variant_type tpbrt::texture_handle::to_variant ( ) const
inlineconstexprnoexcept

Conversion to variant.

◆ reflect()

constexpr auto tpbrt::texture_handle::reflect ( ) const
inlineconstexprnoexcept

Conversion to tuple.


The documentation for this struct was generated from the following file: