diff --git a/apps/openmw/mwvr/openxrmanagerimpl.cpp b/apps/openmw/mwvr/openxrmanagerimpl.cpp index b4794c3d8..3ee835e8f 100644 --- a/apps/openmw/mwvr/openxrmanagerimpl.cpp +++ b/apps/openmw/mwvr/openxrmanagerimpl.cpp @@ -188,8 +188,8 @@ namespace MWVR if (!initialized) { initialized = true; - sLogAllXrCalls = Settings::Manager::getBool("log all openxr calls", "VR"); - sContinueOnErrors = Settings::Manager::getBool("continue on errors", "VR"); + sLogAllXrCalls = Settings::Manager::getBool("log all openxr calls", "VR Debug"); + sContinueOnErrors = Settings::Manager::getBool("continue on errors", "VR Debug"); } if (XR_FAILED(res)) { @@ -258,7 +258,7 @@ namespace MWVR XR_EXT_HP_MIXED_REALITY_CONTROLLER_EXTENSION_NAME }; - if (Settings::Manager::getBool("enable XR_EXT_debug_utils", "VR")) + if (Settings::Manager::getBool("enable XR_EXT_debug_utils", "VR Debug")) optionalExtensions.emplace_back(XR_EXT_DEBUG_UTILS_EXTENSION_NAME); for (auto& extension : enumerateExtensions(nullptr)) @@ -339,23 +339,23 @@ namespace MWVR XrDebugUtilsMessengerCreateInfoEXT createInfo{ XR_TYPE_DEBUG_UTILS_MESSENGER_CREATE_INFO_EXT, nullptr }; // Debug message severity levels - if (Settings::Manager::getBool("XR_EXT_debug_utils message level verbose", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message level verbose", "VR Debug")) createInfo.messageSeverities |= XR_DEBUG_UTILS_MESSAGE_SEVERITY_VERBOSE_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message level info", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message level info", "VR Debug")) createInfo.messageSeverities |= XR_DEBUG_UTILS_MESSAGE_SEVERITY_INFO_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message level warning", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message level warning", "VR Debug")) createInfo.messageSeverities |= XR_DEBUG_UTILS_MESSAGE_SEVERITY_WARNING_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message level error", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message level error", "VR Debug")) createInfo.messageSeverities |= XR_DEBUG_UTILS_MESSAGE_SEVERITY_ERROR_BIT_EXT; // Debug message types - if (Settings::Manager::getBool("XR_EXT_debug_utils message type general", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message type general", "VR Debug")) createInfo.messageTypes |= XR_DEBUG_UTILS_MESSAGE_TYPE_GENERAL_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message type validation", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message type validation", "VR Debug")) createInfo.messageTypes |= XR_DEBUG_UTILS_MESSAGE_TYPE_VALIDATION_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message type performance", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message type performance", "VR Debug")) createInfo.messageTypes |= XR_DEBUG_UTILS_MESSAGE_TYPE_PERFORMANCE_BIT_EXT; - if (Settings::Manager::getBool("XR_EXT_debug_utils message type conformance", "VR")) + if (Settings::Manager::getBool("XR_EXT_debug_utils message type conformance", "VR Debug")) createInfo.messageTypes |= XR_DEBUG_UTILS_MESSAGE_TYPE_CONFORMANCE_BIT_EXT; createInfo.userCallback = &xrDebugCallback; diff --git a/apps/openmw/mwvr/vrsession.cpp b/apps/openmw/mwvr/vrsession.cpp index a65b02a34..9529ae766 100644 --- a/apps/openmw/mwvr/vrsession.cpp +++ b/apps/openmw/mwvr/vrsession.cpp @@ -35,7 +35,7 @@ namespace MWVR : mXrSyncPhase{FramePhase::Cull} { mHandDirectedMovement = Settings::Manager::getBool("hand directed movement", "VR"); - auto syncPhase = Settings::Manager::getString("openxr sync phase", "VR"); + auto syncPhase = Settings::Manager::getString("openxr sync phase", "VR Debug"); syncPhase = Misc::StringUtils::lowerCase(syncPhase); if (syncPhase == "update") mXrSyncPhase = FramePhase::Update; @@ -51,10 +51,6 @@ namespace MWVR return; } Log(Debug::Verbose) << "Using openxr sync phase " << syncPhase; - - mUseSteadyClock = Settings::Manager::getBool("use steady clock", "VR"); - if (mUseSteadyClock) - Log(Debug::Verbose) << "Using chrono::steady_clock instead of openxr predicted display times."; } VRSession::~VRSession() diff --git a/apps/openmw/mwvr/vrsession.hpp b/apps/openmw/mwvr/vrsession.hpp index 04b8902e6..ddf479058 100644 --- a/apps/openmw/mwvr/vrsession.hpp +++ b/apps/openmw/mwvr/vrsession.hpp @@ -83,7 +83,6 @@ namespace MWVR FramePhase mXrSyncPhase{ FramePhase::Cull }; bool mHandDirectedMovement{ false }; - bool mUseSteadyClock{ false }; long long mFrames{ 0 }; long long mLastRenderedFrame{ 0 }; long long mLastPredictedDisplayTime{ 0 }; diff --git a/files/settings-default.cfg b/files/settings-default.cfg index 1277c509c..1eeabfbf0 100644 --- a/files/settings-default.cfg +++ b/files/settings-default.cfg @@ -921,9 +921,6 @@ left eye resolution y = auto right eye resolution x = auto right eye resolution y = auto -# Openmw will sync with openxr at the beginning of this phase in the rendering pipeline. From early to late in the pipeline the options are update, cull, draw, and swap in that order. If you experience visual glitches such as frames jittering across your vision, try changing this to an earlier phase. -openxr sync phase = draw - # Determines how quickly you have to move your hand minimum, in meters/second, to perform an attack realistic combat minimum swing velocity = 1.0 @@ -933,9 +930,12 @@ realistic combat maximum swing velocity = 4.0 # Enables controller vibrations when you hit or are hit. haptics enabled = true -# Work around for some preview openxr runtimes whose display time predictions do not work -# Use this if tracking seems crazy. -use steady clock = false +# If true, movement direction is taken from the left hand tracker, instead of your head. +hand directed movement = false + +[VR Debug] +# Openmw will sync with openxr at the beginning of this phase in the rendering pipeline. From early to late in the pipeline the options are update, cull, draw, and swap in that order. If you experience visual glitches such as frames jittering across your vision, try changing this to an earlier phase. +openxr sync phase = draw # Log all calls to openxr, not just ones that fail. Useful for debugging. log all openxr calls = false @@ -943,9 +943,6 @@ log all openxr calls = false # If false, openmw will quit with an exception if an openxr call fails for any reason continue on errors = true -# If true, movement direction is taken from the left hand tracker, instead of your head. -hand directed movement = false - # If true, enable openxr debug functionality via the XR_EXT_debug_utils extension enable XR_EXT_debug_utils = false @@ -958,5 +955,4 @@ XR_EXT_debug_utils message level error = true XR_EXT_debug_utils message type general = true XR_EXT_debug_utils message type validation = true XR_EXT_debug_utils message type performance = true -XR_EXT_debug_utils message type conformance = true - +XR_EXT_debug_utils message type conformance = true \ No newline at end of file