|
Blender V5.3
|
#include <gpu_shader_private.hh>
Inherited by blender::gpu::GLShaderCompiler, blender::gpu::GLSubprocessShaderCompiler, and blender::gpu::MTLShaderCompiler.
Public Member Functions | |
| virtual void | specialize_shader (const ShaderSpecialization &) |
Protected Member Functions | |
| void | destruct_compilation_worker () |
ShaderCompiler | |
| ShaderCompiler (uint32_t threads_count=1, GPUWorker::ContextType context_type=GPUWorker::ContextType::PerThread, bool support_specializations=false) | |
| virtual | ~ShaderCompiler () |
| Shader * | compile (const shader::ShaderCreateInfo &info, bool is_codegen_only) |
| virtual Shader * | compile_shader (const shader::ShaderCreateInfo &info) |
| AsyncCompilationHandle | async_compilation (const shader::ShaderCreateInfo *info, CompilationPriority priority) |
| void | async_compilation_cancel (AsyncCompilationHandle &handle) |
| bool | async_compilation_is_ready (AsyncCompilationHandle handle) |
| Shader * | async_compilation_finalize (AsyncCompilationHandle &handle) |
| AsyncSpecializationHandle | async_specialization (const ShaderSpecialization &specialization, CompilationPriority priority) |
| bool | async_specialization_is_ready (AsyncSpecializationHandle &handle) |
| bool | is_compiling () |
| void | wait_for_all () |
| void | pause_all () |
| void | continue_all () |
Definition at line 162 of file gpu_shader_private.hh.
| blender::gpu::ShaderCompiler::ShaderCompiler | ( | uint32_t | threads_count = 1, |
| GPUWorker::ContextType | context_type = GPUWorker::ContextType::PerThread, | ||
| bool | support_specializations = false ) |
Definition at line 1055 of file gpu_shader.cc.
References blender::GPU_use_main_context_workaround(), and ShaderCompiler().
Referenced by blender::gpu::GLShaderCompiler::GLShaderCompiler(), blender::gpu::MTLShaderCompiler::MTLShaderCompiler(), and ShaderCompiler().
|
virtual |
Definition at line 1067 of file gpu_shader.cc.
References blender::BLI_assert(), and ~ShaderCompiler().
Referenced by ~ShaderCompiler().
| AsyncCompilationHandle blender::gpu::ShaderCompiler::async_compilation | ( | const shader::ShaderCreateInfo * | info, |
| CompilationPriority | priority ) |
Definition at line 1080 of file gpu_shader.cc.
References async_compilation(), compile(), lock, and blender::gpu::to_work_priority().
Referenced by async_compilation(), and blender::GPU_shader_async_compilation().
| void blender::gpu::ShaderCompiler::async_compilation_cancel | ( | AsyncCompilationHandle & | handle | ) |
Definition at line 1104 of file gpu_shader.cc.
References async_compilation_cancel(), blender::GPU_shader_free(), and lock.
Referenced by async_compilation_cancel(), blender::GPU_shader_async_compilation_cancel(), and blender::GPU_shader_async_specialization_cancel().
| Shader * blender::gpu::ShaderCompiler::async_compilation_finalize | ( | AsyncCompilationHandle & | handle | ) |
Definition at line 1135 of file gpu_shader.cc.
References async_compilation_finalize(), and lock.
Referenced by async_compilation_finalize(), and blender::GPU_shader_async_compilation_finalize().
| bool blender::gpu::ShaderCompiler::async_compilation_is_ready | ( | AsyncCompilationHandle | handle | ) |
Definition at line 1128 of file gpu_shader.cc.
References async_compilation_is_ready(), and lock.
Referenced by async_compilation_is_ready(), and blender::GPU_shader_async_compilation_is_ready().
| AsyncSpecializationHandle blender::gpu::ShaderCompiler::async_specialization | ( | const ShaderSpecialization & | specialization, |
| CompilationPriority | priority ) |
Definition at line 1150 of file gpu_shader.cc.
References async_specialization(), lock, and blender::gpu::to_work_priority().
Referenced by async_specialization(), and blender::GPU_shader_async_specialization().
| bool blender::gpu::ShaderCompiler::async_specialization_is_ready | ( | AsyncSpecializationHandle & | handle | ) |
Definition at line 1172 of file gpu_shader.cc.
References async_specialization_is_ready(), and lock.
Referenced by async_specialization_is_ready(), and blender::GPU_shader_async_specialization_is_ready().
| Shader * blender::gpu::ShaderCompiler::compile | ( | const shader::ShaderCreateInfo & | info, |
| bool | is_codegen_only ) |
Definition at line 795 of file gpu_shader.cc.
References blender::gpu::shader::ShaderCreateInfo::batch_resources_, blender::BLI_assert(), blender::gpu::shader::ShaderCreateInfo::builtins(), blender::gpu::shader::ShaderCreateInfo::builtins_, blender::gpu::shader::ShaderCreateInfo::builtins_combined(), blender::gpu::shader::ShaderCreateInfo::check_error(), CLOG_DEBUG, blender::gpu::shader::ShaderCreateInfo::compilation_constants_, compile(), blender::gpu::shader::ShaderCreateInfo::compute_entry_fn_, blender::gpu::shader::ShaderCreateInfo::compute_source_, blender::gpu::shader::ShaderCreateInfo::do_static_compilation_, blender::gpu::shader::ShaderCreateInfo::fragment_entry_fn_, blender::gpu::shader::ShaderCreateInfo::fragment_outputs_, blender::gpu::shader::ShaderCreateInfo::fragment_source_, blender::G, blender::gpu::shader::ShaderCreateInfo::generated_sources, blender::gpu::shader::ShaderCreateInfo::geometry_resources_, blender::gpu::shader::ShaderCreateInfo::geometry_source_, blender::gpu::Context::get(), blender::gpu::GPUBackend::get(), blender::gpu::ProfileReport::get(), blender::GPU_debug_group_begin(), blender::GPU_debug_group_end(), GPU_DEBUG_SHADER_COMPILATION_GROUP, blender::gpu::shader::gpu_shader_dependency_get_resolved_source(), blender::gpu::shader::ShaderCreateInfo::iface_guard_defines(), blender::gpu::shader::ShaderCreateInfo::FragOut::index, blender::blender::StringRefBase::is_empty(), blender::gpu::shader::ShaderCreateInfo::is_generated_, blender::LOG, blender::gpu::shader::ShaderCreateInfo::name_, blender::gpu::shader::NO_PREPROCESSOR, blender::gpu::shader::NONE, blender::gpu::shader::ShaderCreateInfo::pass_resources_, blender::gpu::shader::ShaderCreateInfo::push_constants_, blender::gpu::shader::ShaderCreateInfo::resource_guard_defines(), blender::standard_defines(), blender::gpu::shader::ShaderCreateInfo::vertex_entry_fn_, blender::gpu::shader::ShaderCreateInfo::vertex_inputs_, blender::gpu::shader::ShaderCreateInfo::vertex_out_interfaces_, and blender::gpu::shader::ShaderCreateInfo::vertex_source_.
Referenced by async_compilation(), compile(), blender::gpu::MTLShaderCompiler::compile_shader(), compile_shader(), blender::GPU_shader_create_from_info(), and blender::GPU_shader_create_from_info_python().
|
virtual |
Reimplemented in blender::gpu::MTLShaderCompiler.
Definition at line 1075 of file gpu_shader.cc.
References compile(), and compile_shader().
Referenced by compile_shader().
| void blender::gpu::ShaderCompiler::continue_all | ( | ) |
Definition at line 1263 of file gpu_shader.cc.
References blender::BLI_assert(), continue_all(), and lock.
Referenced by continue_all(), and blender::GPU_shader_compiler_resume().
|
inlineprotected |
Definition at line 213 of file gpu_shader_private.hh.
| bool blender::gpu::ShaderCompiler::is_compiling | ( | ) |
Definition at line 1241 of file gpu_shader.cc.
References is_compiling(), and lock.
Referenced by blender::GPU_shader_compiler_has_pending_work(), and is_compiling().
| void blender::gpu::ShaderCompiler::pause_all | ( | ) |
Definition at line 1256 of file gpu_shader.cc.
References blender::BLI_assert(), lock, and pause_all().
Referenced by blender::GPU_shader_compiler_pause(), and pause_all().
|
inlinevirtual |
Reimplemented in blender::gpu::GLShaderCompiler, and blender::gpu::MTLShaderCompiler.
Definition at line 227 of file gpu_shader_private.hh.
| void blender::gpu::ShaderCompiler::wait_for_all | ( | ) |
Definition at line 1247 of file gpu_shader.cc.
References blender::BLI_assert(), lock, and wait_for_all().
Referenced by blender::GPU_shader_compiler_wait_for_all(), and wait_for_all().