From 8a7794545c3465aed83061315e31dec8444bf2cd Mon Sep 17 00:00:00 2001 From: Erimel Date: Mon, 26 Oct 2026 15:45:36 -0400 Subject: [PATCH] Fix tracking pause neck --- gui/app/src/index.scss | 10 +++++----- .../src/main/java/dev/slimevr/skeleton/behaviours.kt | 12 +++--------- 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/gui/app/src/index.scss b/gui/app/src/index.scss index 0915ac217..89ba70f57 100644 --- a/gui/app/src/index.scss +++ b/gui/app/src/index.scss @@ -235,11 +235,11 @@ body { --background-80: 7, 20, 7; --background-90: 2, 6, 2; - --accent-background-10: 222, 214, 104; - --accent-background-20: 199, 190, 60; - --accent-background-30: 148, 141, 44; + --accent-background-10: 222, 212, 104; + --accent-background-20: 199, 187, 60; + --accent-background-30: 140, 132, 42; --accent-background-40: 133, 125, 40; - --accent-background-50: 64, 61, 19; + --accent-background-50: 64, 60, 19; --success: 80, 232, 151; --warning: 255, 225, 53; @@ -346,7 +346,7 @@ body { --accent-background-50: 59, 25, 6; --success: 100, 230, 10; - --warning: 240, 190, 50; + --warning: 240, 199, 50; --critical: 220, 40, 110; --special: 227, 89, 34; --window-icon-stroke: 205, 81, 0; diff --git a/server/core/src/main/java/dev/slimevr/skeleton/behaviours.kt b/server/core/src/main/java/dev/slimevr/skeleton/behaviours.kt index bdcd9e836..cb15585a3 100644 --- a/server/core/src/main/java/dev/slimevr/skeleton/behaviours.kt +++ b/server/core/src/main/java/dev/slimevr/skeleton/behaviours.kt @@ -187,7 +187,9 @@ class ComputedSkeletonBehaviour( val ikComputedProcessors: List = emptyList(), val waiter: PreciseWaiter, ) : SkeletonBehaviour { + // BodyParts that are active even when tracking is paused private val ALWAYS_ACTIVE_PARTS = arrayOf(BodyPart.HEAD, BodyPart.NECK) + private val IK_THRESHOLD = 0.002f private val IK_MAX_ITERATIONS = 100 @@ -257,15 +259,7 @@ class ComputedSkeletonBehaviour( } // Use single map for the inputs that we'll mutate for performance - val mutableBoneInputs: InputSkeleton = BodyPartMap( - if (targetState.pausedProcessedBoneInputs != null) { - // If tracking is paused, we only run the skeleton loop for the always active bones (head and neck) - // and add the pausedProcessedBoneInputs later on. - targetState.boneInputs.filter { it.key in ALWAYS_ACTIVE_PARTS } - } else { - targetState.boneInputs - }, - ) + val mutableBoneInputs: InputSkeleton = BodyPartMap(targetState.boneInputs) // Run pre-FK processors (input processors) for (processor in inputProcessors) processor.process(mutableBoneInputs, targetState.skeletonHeight)