|
Blender V4.3
|
#include <eevee_precompute.hh>
Public Member Functions | |
| Precompute (draw::Manager &manager, PrecomputeType type, int3 table_extent) | |
| ~Precompute () | |
| template<typename T > | |
| Vector< T > | data () |
Static Public Member Functions | |
| template<typename VecT > | |
| static void | write_to_pfm (StringRefNull name, Span< VecT > pixels, int64_t n_x, int64_t n_y=1, int64_t n_z=1, int64_t n_w=1) |
| template<typename VecT > | |
| static void | write_to_header (StringRefNull name, Span< VecT > pixels, int64_t n_x, int64_t n_y=1, int64_t n_z=1, int64_t n_w=1) |
Create a look-up table of the specified type using GPU compute. Not to be used at runtime in final release. Usage example: Precompute(manager, LUT_GGX_BRDF_SPLIT_SUM, {64, 64, 1}).data<float2>()
Definition at line 26 of file eevee_precompute.hh.
| blender::eevee::Precompute::Precompute | ( | draw::Manager & | manager, |
| PrecomputeType | type, | ||
| int3 | table_extent ) |
Definition at line 15 of file eevee_precompute.cc.
References blender::draw::detail::PassBase< DrawCommandBufType >::barrier(), blender::draw::detail::PassBase< DrawCommandBufType >::bind_image(), blender::draw::detail::PassBase< DrawCommandBufType >::dispatch(), blender::math::divide_ceil(), blender::draw::Texture::ensure_3d(), GPU_BARRIER_TEXTURE_UPDATE, GPU_DATA_FLOAT, GPU_RGBA32F, GPU_shader_create_from_info_name(), GPU_shader_free(), GPU_TEXTURE_USAGE_HOST_READ, GPU_TEXTURE_USAGE_SHADER_WRITE, LUT_WORKGROUP_SIZE, blender::draw::detail::PassBase< DrawCommandBufType >::push_constant(), blender::draw::Texture::read(), blender::draw::detail::PassBase< DrawCommandBufType >::shader_set(), and blender::draw::Manager::submit().
| blender::eevee::Precompute::~Precompute | ( | ) |
Definition at line 40 of file eevee_precompute.cc.
References MEM_SAFE_FREE.
|
inlinestatic |
Write a the content of a texture as a C++ header file array. The content is to be copied to eevee_lut.cc and formatted with make format.
Definition at line 98 of file eevee_precompute.hh.
|
inlinestatic |
Write a the content of a texture to a PFM image file for inspection. OpenGL texture coordinate convention with Y up is respected.
Definition at line 51 of file eevee_precompute.hh.
References blender::draw::BLI_STATIC_ASSERT(), data(), and file.