From 9eabd202fb3891202351afc5d8d447adb1b64a82 Mon Sep 17 00:00:00 2001 From: BabbleBones Date: Wed, 13 Dec 2023 23:14:25 -0500 Subject: [PATCH 1/2] feat: increase performance substantially with min period --- src/profiles/lighthouse.rs | 1 + src/profiles/openhmd.rs | 1 + src/profiles/survive.rs | 1 + src/profiles/wivrn.rs | 1 + src/profiles/wmr.rs | 1 + 5 files changed, 5 insertions(+) diff --git a/src/profiles/lighthouse.rs b/src/profiles/lighthouse.rs index 21d725b..f6a1c34 100644 --- a/src/profiles/lighthouse.rs +++ b/src/profiles/lighthouse.rs @@ -14,6 +14,7 @@ pub fn lighthouse_profile() -> Profile { environment.insert("XRT_COMPOSITOR_COMPUTE".into(), "1".into()); environment.insert("XRT_DEBUG_GUI".into(), "1".into()); environment.insert("XRT_CURATED_GUI".into(), "1".into()); + environment.insert("U_PACING_APP_USE_MIN_FRAME_PERIOD".into(), "1".into()); environment.insert( "LD_LIBRARY_PATH".into(), format!("{pfx}/lib:{pfx}/lib64", pfx = prefix), diff --git a/src/profiles/openhmd.rs b/src/profiles/openhmd.rs index eaded5f..d7ac3e9 100644 --- a/src/profiles/openhmd.rs +++ b/src/profiles/openhmd.rs @@ -17,6 +17,7 @@ pub fn openhmd_profile() -> Profile { environment.insert("XRT_COMPOSITOR_COMPUTE".into(), "1".into()); environment.insert("XRT_DEBUG_GUI".into(), "1".into()); environment.insert("XRT_CURATED_GUI".into(), "1".into()); + environment.insert("U_PACING_APP_USE_MIN_FRAME_PERIOD".into(), "1".into()); environment.insert( "LD_LIBRARY_PATH".into(), format!("{pfx}/lib:{pfx}/lib64", pfx = prefix), diff --git a/src/profiles/survive.rs b/src/profiles/survive.rs index 1e11e90..67fa07d 100644 --- a/src/profiles/survive.rs +++ b/src/profiles/survive.rs @@ -19,6 +19,7 @@ pub fn survive_profile() -> Profile { environment.insert("SURVIVE_TIMECODE_OFFSET_MS".into(), "-6.94".into()); environment.insert("XRT_DEBUG_GUI".into(), "1".into()); environment.insert("XRT_CURATED_GUI".into(), "1".into()); + environment.insert("U_PACING_APP_USE_MIN_FRAME_PERIOD".into(), "1".into()); environment.insert( "LD_LIBRARY_PATH".into(), format!("{pfx}/lib:{pfx}/lib64", pfx = prefix), diff --git a/src/profiles/wivrn.rs b/src/profiles/wivrn.rs index 10f356f..25e5cdd 100644 --- a/src/profiles/wivrn.rs +++ b/src/profiles/wivrn.rs @@ -15,6 +15,7 @@ pub fn wivrn_profile() -> Profile { ); environment.insert("XRT_DEBUG_GUI".into(), "1".into()); environment.insert("XRT_CURATED_GUI".into(), "1".into()); + environment.insert("U_PACING_APP_USE_MIN_FRAME_PERIOD".into(), "1".into()); Profile { uuid: "wivrn-default".into(), name: format!("WiVRn - {name} Default", name = APP_NAME), diff --git a/src/profiles/wmr.rs b/src/profiles/wmr.rs index 7278ff5..bf7d07c 100644 --- a/src/profiles/wmr.rs +++ b/src/profiles/wmr.rs @@ -17,6 +17,7 @@ pub fn wmr_profile() -> Profile { environment.insert("XRT_COMPOSITOR_COMPUTE".into(), "1".into()); environment.insert("XRT_DEBUG_GUI".into(), "1".into()); environment.insert("XRT_CURATED_GUI".into(), "1".into()); + environment.insert("U_PACING_APP_USE_MIN_FRAME_PERIOD".into(), "1".into()); environment.insert( "LD_LIBRARY_PATH".into(), format!("{pfx}/lib:{pfx}/lib64", pfx = prefix), From c74ed5d60c6b870170c4b8cebb12464c509f0eee Mon Sep 17 00:00:00 2001 From: BabbleBones Date: Wed, 13 Dec 2023 23:24:39 -0500 Subject: [PATCH 2/2] feat: add min period env var description --- src/env_var_descriptions.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/env_var_descriptions.rs b/src/env_var_descriptions.rs index 32ca636..d71b94b 100644 --- a/src/env_var_descriptions.rs +++ b/src/env_var_descriptions.rs @@ -5,6 +5,7 @@ pub static ENV_VAR_DESCRIPTIONS: Map<&str, &str> = phf_map! { "XRT_COMPOSITOR_SCALE_PECENTAGE" => "Render resolution percentage. A percentage higher than the native resolution (>100) will help with antialiasing and image clarity.", "XRT_COMPOSITOR_COMPUTE" => "Set to 1 to use GPU compute for the OpenXR compositor.", + "U_PACING_APP_USE_MIN_FRAME_PERIOD" => "Set to 1 to unlimit the compositor refresh from a power of two of your HMD refresh, typically provides a large performance boost.", "SURVIVE_GLOBALSCENESOLVER" => "Continuously recalibrate lighthouse tracking during use. In the current state it's recommended to disable this feature by setting this value to 0.", // "SURVIVE_TIMECODE_OFFSET_MS" => "",