diff options
author | Julian Eisel <eiseljulian@gmail.com> | 2019-07-23 03:06:08 +0300 |
---|---|---|
committer | Julian Eisel <eiseljulian@gmail.com> | 2019-07-23 03:06:08 +0300 |
commit | d58eb8d29dcdde46511384c317a73112bfea5aac (patch) | |
tree | 9188b847fa5ffd18a95b254e5615138a3eeb352e /source/creator | |
parent | a4310ba85f658406e8b6c3371ff3c75aea702a7f (diff) |
Add --debug-xr-time command line option for VR frame time info prints
Outputs frame render time in milliseconds and FPS this time would add up
to. We could average times so FPS is a bit more stable, but the
precision of un-averaged results may be helpful too.
Diffstat (limited to 'source/creator')
-rw-r--r-- | source/creator/creator_args.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c index 34c2dd5305a..b5edd0c4b77 100644 --- a/source/creator/creator_args.c +++ b/source/creator/creator_args.c @@ -606,6 +606,7 @@ static int arg_handle_print_help(int UNUSED(argc), const char **UNUSED(argv), vo BLI_argsPrintArgDoc(ba, "--debug-wm"); # ifdef WITH_OPENXR BLI_argsPrintArgDoc(ba, "--debug-xr"); + BLI_argsPrintArgDoc(ba, "--debug-xr-time"); # endif BLI_argsPrintArgDoc(ba, "--debug-all"); BLI_argsPrintArgDoc(ba, "--debug-io"); @@ -950,6 +951,9 @@ static const char arg_handle_debug_mode_generic_set_doc_xr[] = "Enable debug messages for virtual reality contexts.\n" "\tEnables the OpenXR API validation layer, (OpenXR) debug messages and general information " "prints."; +static const char arg_handle_debug_mode_generic_set_doc_xr_time[] = + "\n\t" + "Enable debug messages for virtual reality frame rendering times."; # endif static const char arg_handle_debug_mode_generic_set_doc_jobs[] = "\n\t" @@ -2094,6 +2098,12 @@ void main_args_setup(bContext *C, bArgs *ba) # ifdef WITH_OPENXR BLI_argsAdd( ba, 1, NULL, "--debug-xr", CB_EX(arg_handle_debug_mode_generic_set, xr), (void *)G_DEBUG_XR); + BLI_argsAdd(ba, + 1, + NULL, + "--debug-xr-time", + CB_EX(arg_handle_debug_mode_generic_set, xr_time), + (void *)G_DEBUG_XR_TIME); # endif BLI_argsAdd(ba, 1, NULL, "--debug-all", CB(arg_handle_debug_mode_all), NULL); |