|
Blender V4.3
|
#include <algorithm>#include "BLI_listbase.h"#include "BLI_rect.h"#include "BLI_string.h"#include "BKE_global.hh"#include "BLF_api.hh"#include "MEM_guardedalloc.h"#include "draw_manager_c.hh"#include "GPU_debug.hh"#include "GPU_texture.hh"#include "UI_resources.hh"#include "draw_manager_profiling.hh"Go to the source code of this file.
Classes | |
| struct | DRWTimer |
| struct | DRWTimerPool |
Macros | |
| #define | MAX_TIMER_NAME 32 |
| #define | MAX_NESTED_TIMER 8 |
| #define | MIM_RANGE_LEN 8 |
| #define | GPU_TIMER_FALLOFF 0.1 |
Functions | |
| void | DRW_stats_free () |
| void | DRW_stats_begin () |
| static DRWTimer * | drw_stats_timer_get () |
| static void | drw_stats_timer_start_ex (const char *name, const bool is_query) |
| void | DRW_stats_group_start (const char *name) |
| void | DRW_stats_group_end () |
| void | DRW_stats_query_start (const char *name) |
| void | DRW_stats_query_end () |
| void | DRW_stats_reset () |
| static void | draw_stat_5row (const rcti *rect, int u, int v, const char *txt, const int size) |
| static void | draw_stat (const rcti *rect, int u, int v, const char *txt, const int size) |
| void | DRW_stats_draw (const rcti *rect) |
Variables | |
| static struct DRWTimerPool | DTP = {nullptr} |
| #define GPU_TIMER_FALLOFF 0.1 |
Definition at line 33 of file draw_manager_profiling.cc.
Referenced by DRW_stats_reset().
| #define MAX_NESTED_TIMER 8 |
Definition at line 31 of file draw_manager_profiling.cc.
Referenced by DRW_stats_draw(), and DRW_stats_reset().
| #define MAX_TIMER_NAME 32 |
Definition at line 30 of file draw_manager_profiling.cc.
| #define MIM_RANGE_LEN 8 |
Definition at line 32 of file draw_manager_profiling.cc.
Referenced by DRW_stats_begin(), and drw_stats_timer_get().
Definition at line 206 of file draw_manager_profiling.cc.
References BLF_draw_default(), v, rcti::xmin, and rcti::ymax.
Referenced by DRW_stats_draw().
|
static |
Definition at line 197 of file draw_manager_profiling.cc.
References BLF_draw_default(), v, rcti::xmin, and rcti::ymax.
Referenced by DRW_stats_draw().
| void DRW_stats_begin | ( | ) |
Definition at line 65 of file draw_manager_profiling.cc.
References DRWTimerPool::chunk_count, DRW_stats_free(), DTP, DRWTimerPool::end_increment, G, DRWTimerPool::is_querying, DRWTimerPool::is_recording, MEM_callocN, MIM_RANGE_LEN, DRWTimerPool::timer_count, DRWTimerPool::timer_increment, and DRWTimerPool::timers.
Referenced by DRW_draw_render_loop_2d_ex(), and DRW_draw_render_loop_ex().
| void DRW_stats_draw | ( | const rcti * | rect | ) |
Definition at line 212 of file draw_manager_profiling.cc.
References BLF_batch_draw_begin(), BLF_batch_draw_end(), BLF_default(), BLI_assert, double(), draw_stat(), draw_stat_5row(), DRW_ENABLED_ENGINE_ITER, DRW_view_data_cache_time_get(), DST, DTP, G, GPU_texture_memory_usage_get(), GPU_vertbuf_get_memory_usage(), MAX_NESTED_TIMER, SNPRINTF, STRNCPY, TH_TEXT_HI, DRWTimer::time_average, timer, DRWTimerPool::timer_increment, DRWTimerPool::timers, UI_FontThemeColor(), v, and DRWManager::view_data_active.
Referenced by DRW_draw_callbacks_post_scene(), and DRW_draw_render_loop_2d_ex().
| void DRW_stats_free | ( | ) |
Definition at line 53 of file draw_manager_profiling.cc.
References DTP, MEM_freeN(), and DRWTimerPool::timers.
Referenced by DRW_engines_free(), and DRW_stats_begin().
| void DRW_stats_group_end | ( | ) |
Definition at line 129 of file draw_manager_profiling.cc.
References BLI_assert, DTP, DRWTimerPool::end_increment, GPU_debug_group_end(), DRWTimerPool::is_querying, and DRWTimerPool::is_recording.
Referenced by blender::workbench::DofPass::draw(), blender::eevee::VolumeModule::draw_prepass(), drw_engines_draw_scene(), gpencil_draw_mask(), GPENCIL_draw_object(), OVERLAY_outline_draw(), blender::eevee::DeferredPipeline::render(), blender::eevee::DepthOfField::render(), blender::eevee::ForwardPipeline::render(), blender::eevee::MotionBlurModule::render(), blender::eevee::RayTraceModule::render(), blender::eevee::ShadingView::render(), blender::eevee::ShadowModule::set_view(), and blender::eevee::IrradianceBake::surfels_create().
| void DRW_stats_group_start | ( | const char * | name | ) |
Use this to group the queries. It does NOT keep track of the time, it only sum what the queries inside it.
Definition at line 122 of file draw_manager_profiling.cc.
References drw_stats_timer_start_ex(), and GPU_debug_group_begin().
Referenced by blender::workbench::DofPass::draw(), blender::eevee::VolumeModule::draw_prepass(), drw_engines_draw_scene(), gpencil_draw_mask(), GPENCIL_draw_object(), OVERLAY_outline_draw(), blender::eevee::DeferredPipeline::render(), blender::eevee::DepthOfField::render(), blender::eevee::ForwardPipeline::render(), blender::eevee::MotionBlurModule::render(), blender::eevee::RayTraceModule::render(), blender::eevee::ShadingView::render(), blender::eevee::ShadowModule::set_view(), and blender::eevee::IrradianceBake::surfels_create().
| void DRW_stats_query_end | ( | ) |
Definition at line 144 of file draw_manager_profiling.cc.
References BLI_assert, DTP, DRWTimerPool::end_increment, GPU_debug_group_end(), DRWTimerPool::is_querying, and DRWTimerPool::is_recording.
Referenced by drw_draw_pass_ex().
| void DRW_stats_query_start | ( | const char * | name | ) |
Definition at line 138 of file draw_manager_profiling.cc.
References drw_stats_timer_start_ex(), and GPU_debug_group_begin().
Referenced by drw_draw_pass_ex().
| void DRW_stats_reset | ( | ) |
Definition at line 155 of file draw_manager_profiling.cc.
References BLI_assert, BLI_assert_msg, DTP, DRWTimerPool::end_increment, GPU_TIMER_FALLOFF, DRWTimerPool::is_recording, MAX_NESTED_TIMER, timer, DRWTimerPool::timer_increment, and DRWTimerPool::timers.
Referenced by DRW_draw_render_loop_2d_ex(), and DRW_draw_render_loop_ex().
|
static |
Definition at line 86 of file draw_manager_profiling.cc.
References DRWTimerPool::chunk_count, DTP, MEM_recallocN, MIM_RANGE_LEN, DRWTimerPool::timer_count, DRWTimerPool::timer_increment, DRWTimerPool::timers, and UNLIKELY.
Referenced by drw_stats_timer_start_ex().
|
static |
Definition at line 99 of file draw_manager_profiling.cc.
References BLI_assert, drw_stats_timer_get(), DTP, DRWTimerPool::end_increment, DRWTimerPool::is_querying, DRWTimerPool::is_recording, STRNCPY, timer, and DRWTimerPool::timer_increment.
Referenced by DRW_stats_group_start(), and DRW_stats_query_start().
|
static |