Blender V4.3
GPUPass Struct Reference

Public Attributes

GPUPassnext
GPUShadershader
GPUCodegenCreateInfocreate_info = nullptr
uint refcount
int gc_timestamp
eGPUMaterialEngine engine
uint32_t hash
bool compiled
bool compilation_requested
bool should_optimize
bool cached
ThreadMutex shader_creation_mutex
BatchHandle async_compilation_handle

Detailed Description

Definition at line 90 of file gpu_codegen.cc.

Member Data Documentation

◆ async_compilation_handle

◆ cached

bool GPUPass::cached

Whether pass is in the GPUPass cache.

Definition at line 111 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), gpu_pass_cache_insert_after(), and GPU_pass_release().

◆ compilation_requested

bool GPUPass::compilation_requested

If this pass is already being_compiled (A GPUPass can be shared by multiple GPUMaterials).

Definition at line 106 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), and GPU_pass_begin_compilation().

◆ compiled

bool GPUPass::compiled

Did we already tried to compile the attached GPUShader.

Definition at line 104 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), GPU_pass_begin_async_compilation(), GPU_pass_finalize_compilation(), and gpu_pass_is_valid().

◆ create_info

◆ engine

eGPUMaterialEngine GPUPass::engine

The engine type this pass is compiled for.

Definition at line 100 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), and gpu_pass_cache_resolve_collision().

◆ gc_timestamp

int GPUPass::gc_timestamp

The last time the refcount was greater than 0.

Definition at line 98 of file gpu_codegen.cc.

◆ hash

uint32_t GPUPass::hash

Identity hash generated from all GLSL code.

Definition at line 102 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), and gpu_pass_cache_resolve_collision().

◆ next

◆ refcount

uint GPUPass::refcount

Orphaned GPUPasses gets freed by the garbage collector.

Definition at line 96 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), GPU_pass_acquire(), gpu_pass_free(), and GPU_pass_release().

◆ shader

◆ shader_creation_mutex

ThreadMutex GPUPass::shader_creation_mutex

Protects pass shader from being created from multiple threads at the same time.

Definition at line 113 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), GPU_pass_async_compilation_try_finalize(), GPU_pass_begin_async_compilation(), GPU_pass_compile(), and gpu_pass_free().

◆ should_optimize

bool GPUPass::should_optimize

Hint that an optimized variant of this pass should be created based on a complexity heuristic during pass code generation.

Definition at line 109 of file gpu_codegen.cc.

Referenced by GPU_generate_pass(), and GPU_pass_should_optimize().


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