Blender
V3.3
|
#include <shader_eval.h>
Public Member Functions | |
ShaderEval (Device *device, Progress &progress) | |
bool | eval (const ShaderEvalType type, const int max_num_inputs, const int num_channels, const function< int(device_vector< KernelShaderEvalInput > &)> &fill_input, const function< void(device_vector< float > &)> &read_output) |
Protected Member Functions | |
bool | eval_cpu (Device *device, const ShaderEvalType type, device_vector< KernelShaderEvalInput > &input, device_vector< float > &output, const int64_t work_size) |
bool | eval_gpu (Device *device, const ShaderEvalType type, device_vector< KernelShaderEvalInput > &input, device_vector< float > &output, const int64_t work_size) |
Protected Attributes | |
Device * | device_ |
Progress & | progress_ |
Definition at line 24 of file integrator/shader_eval.h.
CCL_NAMESPACE_BEGIN ShaderEval::ShaderEval | ( | Device * | device, |
Progress & | progress | ||
) |
Definition at line 18 of file shader_eval.cpp.
bool ShaderEval::eval | ( | const ShaderEvalType | type, |
const int | max_num_inputs, | ||
const int | num_channels, | ||
const function< int(device_vector< KernelShaderEvalInput > &)> & | fill_input, | ||
const function< void(device_vector< float > &)> & | read_output | ||
) |
Definition at line 23 of file shader_eval.cpp.
References DCHECK_EQ, DCHECK_LE, device_, DEVICE_CPU, eval_cpu(), eval_gpu(), Device::foreach_device(), Device::info, input, MEM_READ_ONLY, MEM_READ_WRITE, output, DeviceInfo::type, type, and VLOG_WORK.
Referenced by GeometryManager::displace(), shade_background_pixels(), and Hair::update_shadow_transparency().
|
protected |
Definition at line 76 of file shader_eval.cpp.
References DeviceInfo::cpu_threads, Progress::get_cancel(), Device::get_cpu_kernel_thread_globals(), Device::get_cpu_kernels(), Device::info, input, output, blender::threading::parallel_for(), progress_, CPUKernels::shader_eval_background, SHADER_EVAL_BACKGROUND, CPUKernels::shader_eval_curve_shadow_transparency, SHADER_EVAL_CURVE_SHADOW_TRANSPARENCY, CPUKernels::shader_eval_displace, SHADER_EVAL_DISPLACE, type, work_index, and work_size.
Referenced by eval().
|
protected |
Definition at line 122 of file shader_eval.cpp.
References blender::io::obj::chunk_size, DEVICE_KERNEL_SHADER_EVAL_BACKGROUND, DEVICE_KERNEL_SHADER_EVAL_CURVE_SHADOW_TRANSPARENCY, DEVICE_KERNEL_SHADER_EVAL_DISPLACE, Progress::get_cancel(), Device::gpu_queue_create(), input, kernel, min, output, progress_, queue, SHADER_EVAL_BACKGROUND, SHADER_EVAL_CURVE_SHADOW_TRANSPARENCY, SHADER_EVAL_DISPLACE, type, and work_size.
Referenced by eval().
|
protected |
Definition at line 48 of file integrator/shader_eval.h.
Referenced by eval(), and ShaderEval().
|
protected |
Definition at line 49 of file integrator/shader_eval.h.
Referenced by eval_cpu(), and eval_gpu().