From 95bd51fc81947692d11e51fd1b0a28cb121849fb Mon Sep 17 00:00:00 2001 From: Patrick Nicolas Date: Wed, 19 Jun 2024 16:58:12 +0200 Subject: [PATCH] Add lowpass filtering on tracking offset --- client/scenes/stream_tracking.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/scenes/stream_tracking.cpp b/client/scenes/stream_tracking.cpp index 488f367c..5080bf41 100644 --- a/client/scenes/stream_tracking.cpp +++ b/client/scenes/stream_tracking.cpp @@ -242,5 +242,5 @@ void scenes::stream::tracking() void scenes::stream::operator()(to_headset::prediction_offset && packet) { if (packet.offset.count() >= 0) - tracking_prediction_offset = packet.offset.count(); + tracking_prediction_offset = std::lerp(packet.offset.count(), tracking_prediction_offset.load(), 0.2); }