mirror of
https://github.com/SlimeVR/SlimeVR-Server.git
synced 2026-04-06 02:01:58 +02:00
Fix mocap mode breaking on startup (#1046)
This commit is contained in:
@@ -622,7 +622,11 @@ class HumanSkeleton(
|
||||
val extendedPelvisRot = extendedPelvisYawRoll(leftLegRot, rightLegRot, hipRot)
|
||||
|
||||
// Interpolate between the hipRot and extendedPelvisRot
|
||||
val newHipRot = hipRot.interpR(extendedPelvisRot, hipLegsAveraging)
|
||||
val newHipRot = if (extendedPelvisRot.lenSq() != 0.0f) {
|
||||
hipRot.interpR(extendedPelvisRot, hipLegsAveraging)
|
||||
} else {
|
||||
Quaternion.IDENTITY
|
||||
}
|
||||
|
||||
// Set new hip rotation
|
||||
hipBone.setRotation(newHipRot)
|
||||
|
||||
Reference in New Issue
Block a user