-
Notifications
You must be signed in to change notification settings - Fork 331
FIX: XR input replay preserves device usages #2294
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
Enhance InputEventTrace to store and retrieve device usages facilitating accurate device recreation during input replay. This fixes XR devices not replaying due not writing its Left/Right usages Also included original device resetting to avoid incorrect rest state passthrough input to override replay input
FIX: XR input replay preserves device usages
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
🤖 Helpful? Please react with 👍/👎 | Questions❓Please reach out in Slack #ask-u-pr-agent |
PR Code Suggestions ✨Explore these optional code suggestions:
🤖 Helpful? Please react with 👍/👎 | Questions❓Please reach out in Slack #ask-u-pr-agent |
|||||||||||

Description
Enhance
InputEventTraceso device usages (e.g. LeftHand, RightHand) are captured, serialized, and restored when recording and replaying input. This prevents XR devices recreated from traces from losing their usages and failing to match XR control schemes or being overridden by live input.Key changes:
DeviceInfowhen tracing input events, allowing accurate recreation of usages during replay.WriteToandReadFrommethods now handle the newm_UsagesJsonfield so usages are included in the trace file and restored on load.UsageChangednotification is triggered to ensure XR devices correctly participate in action resolution and control schemes.UsagesJsonWrapperto serialize/deserialize device usages as JSON, with helpers to convert between arrays andReadOnlyArray<InternedString>.Testing status & QA
No new automated tests have been added.
Overall Product Risks
Complexity: low
Halo Effect: Low
Potential risk areas:
Comments to reviewers
Main things to focus on:
Note
On some headsets (e.g. Meta Quest), the XRHMD tracking state may remain active even when the device appears idle. In those cases, replayed rotation can still compete with live HMD rotation unless rotation input is configured accordingly (e.g. PassThrough mode Input Action or headset powered off). This appears to be platform/Input system behaviour rather than an InputEventTrace issue.
Checklist
Before review:
Changed,Fixed,Addedsections.Area_CanDoX,Area_CanDoX_EvenIfYIsTheCase,Area_WhenIDoX_AndYHappens_ThisIsTheResult.During merge:
NEW: ___.FIX: ___.DOCS: ___.CHANGE: ___.RELEASE: 1.1.0-preview.3.