From da4efaeb87b74f73bd5b640eb70132521a1db5cb Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 16 Mar 2018 12:24:08 +0100 Subject: Depsgraph: Support colored addresses in debug prints Enabled with --debug-depsgraph-pretty, only works with ANSI terminals. Thanks Bastien for review! --- source/creator/creator_args.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/creator') diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c index 04a8ae8c28f..25f8d732c58 100644 --- a/source/creator/creator_args.c +++ b/source/creator/creator_args.c @@ -761,6 +761,8 @@ static const char arg_handle_debug_mode_generic_set_doc_depsgraph_eval[] = "\n\tEnable debug messages from dependency graph related on evaluation."; static const char arg_handle_debug_mode_generic_set_doc_depsgraph_no_threads[] = "\n\tSwitch dependency graph to a single threaded evaluation."; +static const char arg_handle_debug_mode_generic_set_doc_depsgraph_pretty[] = +"\n\tEnable colors for dependency graph debug messages."; static const char arg_handle_debug_mode_generic_set_doc_gpumem[] = "\n\tEnable GPU memory stats in status bar."; @@ -1878,6 +1880,8 @@ void main_args_setup(bContext *C, bArgs *ba, SYS_SystemHandle *syshandle) CB_EX(arg_handle_debug_mode_generic_set, depsgraph_time), (void *)G_DEBUG_DEPSGRAPH_TIME); BLI_argsAdd(ba, 1, NULL, "--debug-depsgraph-no-threads", CB_EX(arg_handle_debug_mode_generic_set, depsgraph_no_threads), (void *)G_DEBUG_DEPSGRAPH_NO_THREADS); + BLI_argsAdd(ba, 1, NULL, "--debug-depsgraph-pretty", + CB_EX(arg_handle_debug_mode_generic_set, depsgraph_pretty), (void *)G_DEBUG_DEPSGRAPH_PRETTY); BLI_argsAdd(ba, 1, NULL, "--debug-gpumem", CB_EX(arg_handle_debug_mode_generic_set, gpumem), (void *)G_DEBUG_GPU_MEM); -- cgit v1.2.3