|
Blender V4.3
|
#include "BLI_sys_types.h"Go to the source code of this file.
Classes | |
| struct | blender::gpu::DebugScope |
| struct | blender::gpu::DebugScope::ScopedCapture |
Namespaces | |
| namespace | blender |
| namespace | blender::gpu |
Macros | |
| #define | GPU_DEBUG_SHADER_COMPILATION_GROUP "Shader Compilation" |
Functions | |
| void | GPU_debug_group_begin (const char *name) |
| void | GPU_debug_group_end () |
| void | GPU_debug_get_groups_names (int name_buf_len, char *r_name_buf) |
| bool | GPU_debug_group_match (const char *ref) |
| void | GPU_debug_capture_begin (const char *title) |
| void | GPU_debug_capture_end () |
| void * | GPU_debug_capture_scope_create (const char *name) |
| bool | GPU_debug_capture_scope_begin (void *scope) |
| void | GPU_debug_capture_scope_end (void *scope) |
Helpers for GPU / drawing debugging.
GPU debug capture usage example:
Will trigger a capture and load it inside RenderDoc or Xcode.
Capture scope can be sprinkled around the codebase for easier selective capture.
They are listed from inside Xcode (on Mac) when doing a Metal capture.
OpenGL and Vulkan backend need to use the --debug-gpu-scope-capture launch argument to specify which scope to capture. Building with RenderDoc API support is required for this launch option to be available.
They can be nested but only one can be captured at a time.
Definition in file GPU_debug.hh.
| #define GPU_DEBUG_SHADER_COMPILATION_GROUP "Shader Compilation" |
Definition at line 66 of file GPU_debug.hh.
Referenced by blender::gpu::ShaderCompiler::compile(), and blender::gpu::debug::debug_callback().
| void GPU_debug_capture_begin | ( | const char * | title | ) |
GPU Frame capture support.
Allows instantaneous frame capture of GPU calls between begin/end.
| title | Optional title to set for the frame capture. |
Definition at line 78 of file gpu_debug.cc.
References blender::gpu::Context::debug_capture_begin(), blender::gpu::Context::debug_is_capturing, G, G_DEBUG_GPU, blender::gpu::Context::get(), and GPU_finish().
Referenced by blender::ed::greasepencil::image_render::image_render_begin(), and blender::gpu::GPUTest::SetUp().
| void GPU_debug_capture_end | ( | ) |
Definition at line 93 of file gpu_debug.cc.
References blender::gpu::Context::debug_capture_end(), blender::gpu::Context::debug_is_capturing, G, G_DEBUG_GPU, blender::gpu::Context::get(), and GPU_finish().
Referenced by blender::ed::greasepencil::image_render::image_render_end(), and blender::gpu::GPUTest::TearDown().
| bool GPU_debug_capture_scope_begin | ( | void * | scope | ) |
Used to declare the region within which GPU calls are captured when the scope is triggered.
| scope | Pointer to capture scope object created with GPU_debug_capture_scope_create. |
Definition at line 123 of file gpu_debug.cc.
References blender::gpu::Context::debug_capture_scope_begin(), blender::gpu::Context::debug_is_capturing, G, G_DEBUG_GPU, blender::gpu::Context::get(), and GPU_finish().
Referenced by blender::gpu::DebugScope::begin_capture(), and blender::gpu::DebugScope::ScopedCapture::ScopedCapture().
| void * GPU_debug_capture_scope_create | ( | const char * | name | ) |
GPU debug frame capture scopes.
Allows creation of a GPU frame capture scope that define a region within which an external GPU Frame capture tool can perform a deferred capture of GPU API calls within the boundary upon user request.
| name | Unique name of capture scope displayed within capture tool. |
Definition at line 109 of file gpu_debug.cc.
References blender::gpu::Context::debug_capture_scope_create(), G, G_DEBUG_GPU, and blender::gpu::Context::get().
Referenced by blender::gpu::DebugScope::DebugScope().
| void GPU_debug_capture_scope_end | ( | void * | scope | ) |
Definition at line 145 of file gpu_debug.cc.
References blender::gpu::Context::debug_capture_scope_end(), blender::gpu::Context::debug_is_capturing, G, G_DEBUG_GPU, blender::gpu::Context::get(), and GPU_finish().
Referenced by blender::gpu::DebugScope::end_capture(), and blender::gpu::DebugScope::ScopedCapture::~ScopedCapture().
| void GPU_debug_get_groups_names | ( | int | name_buf_len, |
| char * | r_name_buf ) |
Return a formatted string showing the current group hierarchy in this format: "Group1 > Group 2 > Group3 > ... > GroupN : "
Definition at line 43 of file gpu_debug.cc.
References BLI_snprintf_rlen(), blender::gpu::Context::debug_stack, blender::gpu::Context::get(), blender::Vector< T, InlineBufferCapacity, Allocator >::is_empty(), and len.
Referenced by blender::gpu::debug::debug_callback().
| void GPU_debug_group_begin | ( | const char * | name | ) |
Definition at line 22 of file gpu_debug.cc.
References blender::Vector< T, InlineBufferCapacity, Allocator >::append(), blender::gpu::Context::debug_group_begin(), blender::gpu::Context::debug_stack, G, G_DEBUG_GPU, blender::gpu::Context::get(), and blender::Vector< T, InlineBufferCapacity, Allocator >::size().
Referenced by blender::draw::command::DrawMultiBuf::bind(), blender::gpu::ShaderCompiler::compile(), blender::draw::View::compute_procedural_bounds(), blender::draw::View::compute_visibility(), blender::draw::DebugDraw::display_to_view(), blender::draw::overlay::Meshes::draw(), blender::draw::overlay::MeshUVs::draw(), blender::draw::overlay::Outline::draw(), blender::draw::overlay::Meshes::draw_color_only(), DRW_draw_region_info(), DRW_stats_group_start(), DRW_stats_query_start(), blender::draw::Manager::end_sync(), external_draw_scene_do_image(), gpu_select_pick_begin(), gpu_select_query_begin(), blender::eevee::DeferredProbePipeline::render(), blender::eevee::LookdevView::render(), blender::eevee::PlanarProbePipeline::render(), blender::eevee::CaptureView::render_probes(), blender::eevee::CaptureView::render_world(), blender::draw::detail::PassBase< DrawCommandBufType >::submit(), wm_draw_window_offscreen(), and wm_draw_window_onscreen().
| void GPU_debug_group_end | ( | ) |
Definition at line 33 of file gpu_debug.cc.
References blender::gpu::Context::debug_group_end(), blender::gpu::Context::debug_stack, G, G_DEBUG_GPU, blender::gpu::Context::get(), and blender::Vector< T, InlineBufferCapacity, Allocator >::pop_last().
Referenced by blender::draw::command::DrawMultiBuf::bind(), blender::gpu::ShaderCompiler::compile(), blender::draw::View::compute_procedural_bounds(), blender::draw::View::compute_visibility(), blender::draw::DebugDraw::display_to_view(), blender::draw::overlay::Meshes::draw(), blender::draw::overlay::MeshUVs::draw(), blender::draw::overlay::Outline::draw(), blender::draw::overlay::Meshes::draw_color_only(), DRW_draw_region_info(), DRW_stats_group_end(), DRW_stats_query_end(), blender::draw::Manager::end_sync(), external_draw_scene_do_image(), gpu_select_pick_end(), gpu_select_query_end(), blender::eevee::DeferredProbePipeline::render(), blender::eevee::LookdevView::render(), blender::eevee::PlanarProbePipeline::render(), blender::eevee::CaptureView::render_probes(), blender::eevee::CaptureView::render_world(), blender::draw::detail::PassBase< DrawCommandBufType >::submit(), wm_draw_window_offscreen(), and wm_draw_window_onscreen().
| bool GPU_debug_group_match | ( | const char * | ref | ) |
Return true if inside a debug group with the same name.
Definition at line 61 of file gpu_debug.cc.
References BLI_assert, blender::gpu::Context::debug_stack, G, G_DEBUG_GPU, and blender::gpu::Context::get().
Referenced by blender::gpu::debug::debug_callback().