Commit Graph
85 Commits
Author SHA1 Message Date
iChris4 59c0e00d3b Disable FPS display by default and update related configuration 2026-09-23 17:19:16 +02:00
iChris4 2a4686191e Add Flat Screen mode for VR races and update settings accordingly 2026-09-23 17:15:53 +02:00
iChris4 b2353e1410 Fix for SDL stalling the pacing thread 2026-09-23 15:28:38 +02:00
iChris4andClaude Opus 5 1d66ae87bf Sit in the cockpit with hands on the wheel by default
First person already seats you in the cockpit, so hand steering belongs with it:
the stick keeps steering until a grip actually takes hold of the wheel, and
nothing else changes until it does. "yaw_pitch" becomes the default anchor for
the same reason - from the driver's seat the vehicle's own climb reads as the
ground rising, where a level horizon reads as the kart sinking away.

Both defaults move together in runtime_config.h, the fresh-config template, the
F10 menu's reset, and both launchers, which mirror the runtime's constants. The
menu's reset also puts the rotation combo back on the default rather than on
"yaw", and now covers hand steering with the other cockpit keys.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-23 02:04:22 +02:00
iChris4 7c6a6da3d5 Implement passthrough feature for menu screens in OpenXR 2026-09-22 18:05:43 +02:00
iChris4andClaude Opus 5 54c07c982b Show the headset settings panel as its own OpenXR quad layer
The panel was drawn into the eye images, so below a 1.00x OpenXR
resolution its 1440x1080 canvas was minified into a small eye region and
the text became hard to read. It is now submitted as a quad layer of its
own over the scene's projection or menu quad, which the compositor samples
directly at any render scale.

Each backend (D3D12, Windows Vulkan, Quest) makes the panel's swapchain
pair (plus two shared buffers on the Quest) the first time the panel
opens. While it is open, the frame hands Aurora one more stereo target
after the eyes, which the bridge fills with the panel texture or a
transparent image. The panel image follows the eyes' displayed/retained
pairing, so a cancelled frame never shows an unwritten panel. The quad
hangs where the pointer's hits are tested. Aurora leaves the panel out of
the eyes in layer mode, and a backend that cannot make the layer falls
back to drawing it into the eyes.

On the Quest, debug.wiicompiled.panel_layer 0 selects the old path at
run time. Measured there at a race start (render_scale 0.8), the layer
costs nothing while the panel is closed; while it is open, app GPU time is
10.5 ms against 9.7 ms drawn into the eyes, with unchanged frame rates.

The replay tests cover lazy creation, cancelled frames, closed and
unplaced panels, and render-first pacing on D3D12 and Windows Vulkan.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-22 16:26:28 +02:00
iChris4andClaude Opus 5 dd7f046214 Toggle the first-person camera with a right thumbstick click
Clicking the right thumbstick flips first person exactly as the F10
checkbox does, and saves it the same way. It works on the VR controllers
in either presentation (with a short tick on the right controller) and on
any other gamepad while VR is running. It never reached the game: SDL's
stick click only lands in Aurora's extended buttons.

A click counts on release, and only if the left thumbstick stayed up and
the headset settings panel stayed closed throughout, so the two-thumbstick
panel chord in gamepad mode never toggles the camera. A gamepad whose
right stick click is bound to a GameCube control on its port, as a button
or in an input expression, keeps it for the game. The XR side only posts
a request; the toggle itself runs on the game thread with the checkbox.

[vr] first_person_toggle_click (default true) and a checkbox under the
camera toggle turn the click off. mkw_vr_camera_toggle_tests covers the
click rule.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-22 15:03:17 +02:00
iChris4andClaude Opus 5 c11a7c9a61 Add USB steering wheel and pedal support
Ported from heurazy's mario-kart-wii-VR-port. F10 > Controllers > USB
wheel and pedals (also in the headset panel) picks and calibrates the
steering axis and both pedals by moving them, and assigns buttons by
pressing them, over raw SDL joysticks: no per-model table or gamepad
mapping, and separate pedals, reversed axes and combined pedal axes all
calibrate the same way. Settings live in PhysicalWheel.toml beside
Config.toml; heurazy's five-button files load unchanged.

The wheel is player 1's GameCube controller. In a race it owns port 0
(steering on the stick, the accelerator on A, the brake pedal braking then
reversing over A and drift, the paddles on R and L), keeping only the
other source's pause and item aim. In menus it adds only deliberate
presses. It arms once every pedal and button is released, stays neutral
in a race while its setup is incomplete, and nothing is opened until it
is enabled. Optional light rumble follows the game's own, capped at 15 %.

Added here: its confirm, a new back button and the steering device's
first hat (D-pad) work the menus, since our VR controllers default to a
Wii Remote and the wheel needs to navigate on its own. Devices SDL
classifies as wheels are marked in the list.

In the VR cockpit the wheel follows the hardware steering and hand
steering steps aside while it drives. README documents setup and
Logitech notes (G HUB, the G29's PS3 switch, shifter gears as buttons);
not yet tried on a physical wheel.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-22 14:53:14 +02:00
iChris4 9b61715ab9 Turn the cockpit wheel with the steering, and add hand steering
Every XR frame in the cockpit seat the pacing thread locates both grips in
the seated frame (the immersive base turned by the lean-back angle, the
frame the eye transforms place the vehicle in) and publishes a driving
snapshot. The wheel or handlebar shows the left stick's steering at the
configured full-lock angle, eased; the vehicle's own wheel reads that angle
on the guest thread.

With hand_steering on (off by default), squeezing a grip near the wheel or
handlebar takes hold of it (a short pulse on grab and release); one or two
hands turn it through heurazy's SteeringWheel, and while it is held the
wheel replaces the left stick's X axis in both the Wii Remote and gamepad
presentations, the stick's Y still aims items, and a holding grip no
longer presses C or a shoulder. The settings panel withholds it like any
other input.

The stereo packet carries the cockpit overlay: the hands, in the runtime's
hand mesh (XR_EXT_hand_tracking + XR_FB_hand_tracking_mesh, requested only
when hand steering is on at launch) or procedural gloves, and the separate
VR wheel or handlebar whenever the vehicle's own is not the one turning.
2026-09-22 03:56:23 +02:00
iChris4 3463813a65 Seat first person in the cockpit and animate the vehicle's own wheel
first_person_seat = "cockpit" (the new default) places the head at the
driver's own eyes, measured once from the character's head bone while the
kart drives straight and undamaged, kept behind the steering wheel, at a
life-size scale (cockpit_units_per_meter, grown with the character's
height and the player's size). "yaw" takes the kart's driving direction
from a level seat frame that follows the simulation's position and
direction, so damage spins and tricks do not turn the seat.
first_person_seat = "custom" keeps the previous offset placement.

At the race draw boundary the vehicle's steering wheel disc (karts) or
handle part (bikes, re-seated level while the bike banks) is decoded from
its MDL0, turned on a copy, and posted to the GX thread for Aurora to
substitute into the player's own draws; the copies are dropped after the
frame's draws. The anchor carries the wheel or handlebar geometry in the
seated frame and the frame's exact scale, which reaches the policy and
aurora_set_stereo_scene_anchor_scaled. If no draw takes the copies for 30
frames the vehicle falls back to the VR wheel, and the log says so.

The wheel copy is matched against RaceCamera::GetViewMtx with no dolly
offset, since the scene camera is only set once the draws run; the log
reports its distance from the scene camera once a second.

Nothing turns the wheel yet: the angle comes from the XR side's driving
snapshot, which the next change publishes.

Guest offsets ported from heurazy's mario-kart-wii-VR-port, each
re-checked against the generated leaf getters and the decompilation.
2026-09-22 03:56:04 +02:00
iChris4 50dc354123 Add the cockpit, steering-wheel and hand-steering building blocks
The pure pieces of the first-person cockpit and hand steering, ported from
heurazy's mario-kart-wii-VR-port: the SteeringWheel grab/turn model, the
native wheel vertex rotation, the level seat stabiliser, the seated-eye and
wheel/handlebar geometry, and the XR_FB_hand_tracking_mesh loader. Adds
openxr_driving.h, the OpenXR-free snapshot the pacing thread will publish for
the guest thread, with the hand-off rule (a held wheel replaces the left
stick's X and releases that hand's grip for the game) and the wheel's
displayed angle.

New [vr] keys: first_person_seat (cockpit), cockpit_units_per_meter (100),
steering_wheel (true), native_steering_wheel (true), hand_steering (false)
and the seven wheel_* tuning keys. Nothing reads them yet.

The fresh-config template now writes the first-person defaults the
constants hold (50 / 1.5 / 0); d86dcb0 updated the constants but not the
template.

Tests: mkw_steering_wheel_tests (the fork's), mkw_vr_cockpit_tests,
mkw_vr_hand_steering_tests.
2026-09-22 03:55:40 +02:00
iChris4 e7b670b2cc Added Vulkan PC OpenXR Support 2026-09-21 00:31:46 +02:00
iChris4 fbc9ce7217 Implement render-first pacing for D3D12 and Vulkan backends; enhance packet management and diagnostics 2026-09-20 17:36:08 +02:00
iChris4 787dbcf7d2 Implement more detailed diagnostics for OpenXR stages 2026-09-20 17:24:16 +02:00
iChris4 6a1641e0b7 Implement GX Thread for Asynchronous Rendering
- Introduced a new GX thread to handle the rendering pipeline, allowing the game thread to post commands without blocking.
- Added `gx_thread.h` and `gx_thread.cpp` to manage the command ring buffer and thread synchronization.
- Updated `vi.cpp` to utilize the GX thread for rendering tasks, improving frame pacing and responsiveness.
- Modified `main.cpp` to configure and start the GX thread, ensuring it integrates with the existing rendering workflow.
- Enhanced `openxr_integration.cpp` to register the GX thread with OpenXR for better performance in VR scenarios.
- Refactored `settings_overlay.cpp` to remove unnecessary waits for the frame worker, as the overlay now draws directly into the game thread's ImGui frame.
- Improved error handling and logging in the GX thread to capture exceptions during command execution.
2026-09-19 22:57:49 +02:00
iChris4 ffa63fa60a Implement render-first pacing for Vulkan backend and enhance view location handling 2026-09-19 20:36:03 +02:00
iChris4 7c981888d6 Set default render scale for VR to 0.8 on Quest and update related configurations 2026-09-19 15:33:27 +02:00
iChris4 e681294709 Refactor OpenXR controller input handling and update settings panel interactions 2026-09-19 15:28:20 +02:00
iChris4 60c443654f Added performance level configuration for OpenXR runtime and enhance Aurora's frame worker 2026-09-19 04:43:47 +02:00
iChris4 d296b3dcb3 Quest: optimize compilation rules, adjust stack protection, and increase indirect dispatch cache size 2026-09-19 03:18:07 +02:00
iChris4 7f2113dbc5 - Added new strings for installation reset prompts and messages in strings.xml.
- Created InstallReset.kt to handle the removal of game files, built games, and mod packs while preserving user data.
- Implemented unit tests for InstallReset to ensure correct functionality and file handling.
- Updated RetroRewindPackTest to include new test cases for update and deletion order.
- Enhanced Vulkan interop and OpenXR integration to support new thread scheduling hints for Android.
- Improved error handling and logging for GPU submission failures in Vulkan backend.
2026-09-19 00:08:58 +02:00
iChris4 d4a3f0b350 Quest Fixed Vulkan pipeline cache management and storage mechanisms 2026-09-18 23:38:55 +02:00
iChris4 d2fa3789b0 Updated Quest Launcher & Added Retro Rewind Automatic Download 2026-09-18 01:27:17 +02:00
iChris4andClaude Opus 5 ee5df403ac Merge upstream/main (v0.2.32) into openxr-work
Brings in the keyboard/mouse rebinding overhaul (#162), the Kamek
skip-return hook fixes (#182, #218), the exit button and controller LED
fix (#221), the autohide-cursor and mute hotkey fix (#211), the Linux
--sysroot plumbing (#224) and the switch to the theofficialgman
dawn-build fork (#215).

Conflicts resolved to keep the VR integration intact:

- settings_overlay.cpp/.h: kept both new declarations. The controller
  rebinding UI takes upstream's click-to-rebind widgets wholesale - our
  only edit there was wrapping the combo width in Scaled(), and
  upstream's bindingWidth is already font-relative, so the headset
  panel still scales. Kept our DrawResolutionMenu() extraction (the VR
  panel reuses it) while adopting upstream's DrawExitPrompt() and its
  new DrawTopBar() prologue; kept our Diagnostics menu alongside
  upstream's exit-button width math. HandleEvents merges both keyboard
  paths, with the VR recenter hotkey now guarded by !g_rebind.active so
  it cannot fire while a binding is being captured.

- AuroraDawnProvider.cmake: dropped our now-dead Android hash block.
  Upstream restructured the pins into an if/elseif chain that already
  covers android/aarch64, with the digest for the new dawn-build fork;
  our leftover block was unreachable and carried the old encounter
  digest.

- Version plumbing (Build-Installer.ps1, Setup.Windows Program.cs and
  csproj): kept this fork's own line, which is 0.2.39 and centralised in
  Launcher/Directory.Build.props, rather than regressing to upstream's
  hardcoded 0.2.32.

Verified: translator 654/654; runtime ctest 14/14 including every VR
test; WiiCompiled and RetroRewind link; aurora gx_fifo_tests 262/263,
the one failure being the TevRegisterLiveness case already documented as
pre-existing on this branch.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-17 23:02:33 +02:00
iChris4 1346e53cd6 Implement OpenXR Settings Panel and Stereo Overlay 2026-09-17 04:32:22 +02:00
iChris4 f222eedf6b Implement log export functionality and OpenXR diagnostics 2026-09-17 02:05:12 +02:00
iChris4 19485b9e8b Implement OpenXR Wii Remote support 2026-09-16 23:58:04 +02:00
iChris4 e52227baf5 Added Android Meta Quest Support 2026-09-16 22:06:34 +02:00
iChris4 49b8602543 Remove OpenXR Vulkan backend implementation files 2026-09-16 22:04:30 +02:00
Nicholas Bly 8705e957c7 Fix autohide cursor + mute hotkey (#211)
* Fix autohide cursor + mute hotkey

* fixes

* Fix rebinding + spacing fixes
2026-09-14 17:00:08 +02:00
Nicholas Bly 4bdaff01fc Add Exit button + controller led fix (#221) 2026-09-13 14:07:54 +02:00
iChris4 c4f386724c Disabled bloom by default 2026-09-10 23:06:46 +02:00
iChris4 715830e89a Updated default value 2026-09-10 22:51:12 +02:00
iChris4 6467c6390c Added support for VR Frame Interpolation 2026-09-10 21:33:34 +02:00
Cristian Boehmandpatchzyy 149cfef608 keyboard and mouse support, rebinding overhaul, analog triggers to digital inputs (#162)
* add keyboard support, analog triggers to digital input, and rebinding overhaul

* Update README.md

* Update README.md

readme typo

* implemented code rabbits suggestions

- Preserved NSO GameCube analog triggers.
  - Made modal closure and Escape cancel every rebind kind.
  - Deduced the native button array size; <array> already existed.
  - Centralized axis/sign decoding.
  - Kept threshold updates live, saving only when editing ends.

* add dimming when in settings and add clear mapping button

* Update settings_overlay.cpp

---------

Co-authored-by: patchzyy <64382339+patchzyy@users.noreply.github.com>
2026-09-10 17:37:38 +02:00
iChris4 ee34fbe419 Online First-person camera anchor fix 2026-09-10 03:56:42 +02:00
iChris4 0353b76baa Online fix 2026-09-10 03:30:03 +02:00
iChris4 5caec70da9 Added Support for VR in Launcher Setup 2026-09-09 20:40:23 +02:00
iChris4 d86dcb0aeb Updated default fpv values 2026-09-09 02:13:05 +02:00
iChris4 f525b9dd75 Fix : XR thread resubmits the last valid frame during stall + Eager Frame Heartbeat option 2026-09-09 01:08:04 +02:00
iChris4 4cf9f60ee7 Added Desktop view selector 2026-09-09 00:18:41 +02:00
iChris4andClaude Opus 5 a138670b37 Merge upstream main (v0.2.31) into openxr-work
Brings in 25 upstream commits: Dolphin-compatible input expressions and
GCPadNew.ini import, NAND setting.txt console identity, empty-MKW-save
handling, rumble toggle, LLVM 22, and CI caching.

The only conflict was runtime/CMakeLists.txt, where both sides appended
test targets after mkw_platform_paths_tests. Both blocks are kept: the VR
first-person test alongside upstream's NAND save/settings, SC serial, and
input expression tests.

runtime_config.h and settings_overlay.cpp auto-merged; the VR settings
menu, recenter hotkey, and stereo/first-person init calls are intact
alongside upstream's InputBindings wiring.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-08 22:32:59 +02:00
iChris4 0e3e2c3dc0 Added Yaw only / Yaw + Pitch / Full rotation options to first-person 2026-09-08 22:17:50 +02:00
iChris4 bd106dd1fe Anchored Main Menu Quad 2026-09-08 21:24:37 +02:00
iChris4 913eda2b3a Added "Lean back angle" option 2026-09-08 20:58:49 +02:00
iChris4 6e7e0f075b Added hotkey/menu recenter & Removed head orientation into the view rotation 2026-09-08 18:38:47 +02:00
iChris4 6440c5bc10 Added First-person "Hide Driver" and "Hide Driver and Kart" & Improved Default FPV Settings 2026-09-08 15:43:52 +02:00
iChris4 2742b8d9a2 Fixes for the First Person Camera 2026-09-08 13:37:28 +02:00
patchzyy e0e362bd99 csnum fix 2026-09-06 15:28:56 +02:00
Wubbzeeandpatchzyy f424536d3b Treat empty MKW save as missing rather than corrupt (#168)
* treat empty mkw save as missing

first-run format zero-fills rksys.dat before any real save; a quit before
the first save left an all-zero file that read back as corrupt and trapped
the user in a delete/recreate loop. read opens now treat an all-zero
rksys.dat as absent (a real save always begins with the RKSD0006 header),
so the game recreates it from scratch. also ignore native build output.

* shorten

* I dont really want to change this to be honest.

* extra safety

---------

Co-authored-by: patchzyy <64382339+patchzyy@users.noreply.github.com>
2026-09-06 11:20:51 +02:00