From 7b94d0c60ced519479c58720e09424f6adce15df Mon Sep 17 00:00:00 2001 From: TheRainTrain Date: Sun, 23 Feb 2025 11:16:13 +0100 Subject: [PATCH] Fix non-existent profile being fetched for bytedance controllers, bump protocol revision --- client/scenes/stream_tracking.cpp | 8 ++++---- common/wivrn_packets.h | 16 +++++----------- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/client/scenes/stream_tracking.cpp b/client/scenes/stream_tracking.cpp index e3f70bc9..c122eabe 100644 --- a/client/scenes/stream_tracking.cpp +++ b/client/scenes/stream_tracking.cpp @@ -488,10 +488,10 @@ void scenes::stream::on_interaction_profile_changed(const XrEventDataInteraction auto profile = session.get_current_interaction_profile(path[i]); spdlog::info("interaction profile for {}: {}", path[i], profile); DO_PROFILE(khr, simple_controller) - DO_PROFILE(bd, pico_neo3_controller) - DO_PROFILE(bd, pico4_controller) - DO_PROFILE(bd, pico4s_controller) - DO_PROFILE(bd, pico_g3_controller) + DO_PROFILE(bytedance, pico_neo3_controller) + DO_PROFILE(bytedance, pico4_controller) + DO_PROFILE(bytedance, pico4s_controller) + DO_PROFILE(bytedance, pico_g3_controller) DO_PROFILE(google, daydream_controller) DO_PROFILE(hp, mixed_reality_controller) DO_PROFILE(htc, vive_controller) diff --git a/common/wivrn_packets.h b/common/wivrn_packets.h index 060a0619..e788046b 100644 --- a/common/wivrn_packets.h +++ b/common/wivrn_packets.h @@ -41,7 +41,7 @@ namespace wivrn // Default port for server to listen, both TCP and UDP static const int default_port = 9757; -static constexpr int protocol_revision = 0; +static constexpr int protocol_revision = 1; enum class device_id : uint8_t { @@ -121,9 +121,10 @@ enum class interaction_profile : uint8_t { none, khr_simple_controller, - bd_pico_neo3_controller, - bd_pico4_controller, - bd_pico_g3_controller, + bytedance_pico_neo3_controller, + bytedance_pico4_controller, + bytedance_pico4s_controller, + bytedance_pico_g3_controller, google_daydream_controller, hp_mixed_reality_controller, htc_vive_controller, @@ -142,13 +143,6 @@ enum class interaction_profile : uint8_t meta_touch_controller_quest_2, samsung_odyssey_controller, valve_index_controller, - // out-of-order to preserve enum ordinals - // otherwise this will force non-p4u users - // to update both their client and server - // for a feature they won't use - // - // TODO: order this correctly when the next major update comes around - bd_pico4s_controller, }; enum video_codec