TODO split to two features: imgui-bt abstraction layer + first component frame graph

Summary:

Test Plan:
Summary:

Test Plan:
This commit is contained in:
icex2
2025-02-07 15:02:36 +01:00
parent 2c00da6232
commit 8282a9f3f4
37 changed files with 1122 additions and 50 deletions
+34
View File
@@ -0,0 +1,34 @@
#include "cconfig/cconfig-util.h"
#include "iidxhook-util/config-debug.h"
#include "util/log.h"
#define IIDXHOOK_CONFIG_DEBUG_ENABLE_FRAME_PERF_GRAPH_KEY "debug.enable_frame_perf_graph"
#define IIDXHOOK_CONFIG_DEBUG_DEFAULT_ENABLE_FRAME_PERF_GRAPH_VALUE false
void iidxhook_config_debug_init(struct cconfig *config)
{
cconfig_util_set_bool(
config,
IIDXHOOK_CONFIG_DEBUG_ENABLE_FRAME_PERF_GRAPH_KEY,
IIDXHOOK_CONFIG_DEBUG_DEFAULT_ENABLE_FRAME_PERF_GRAPH_VALUE,
"Enable frame performance graph overlay");
}
void iidxhook_config_debug_get(
struct iidxhook_config_debug *config_debug, struct cconfig *config)
{
if (!cconfig_util_get_bool(
config,
IIDXHOOK_CONFIG_DEBUG_ENABLE_FRAME_PERF_GRAPH_KEY,
&config_debug->enable_frame_perf_graph,
IIDXHOOK_CONFIG_DEBUG_DEFAULT_ENABLE_FRAME_PERF_GRAPH_VALUE)) {
log_warning(
"Invalid value for key '%s' specified, fallback "
"to default '%d'",
IIDXHOOK_CONFIG_DEBUG_ENABLE_FRAME_PERF_GRAPH_KEY,
IIDXHOOK_CONFIG_DEBUG_DEFAULT_ENABLE_FRAME_PERF_GRAPH_VALUE);
}
}