Perf/performance improvements#8
Merged
Merged
Conversation
added 3 commits
May 29, 2026 14:41
Added - F10 hotkey to toggle inference on/off: disabling stops MediaPipe (frees CPU) and centers the in-game view; re-enabling resumes from the last calibration (no recenter). Rebindable in Settings > Hotkeys. - "Pause preview" button to measure the preview's CPU cost while tracking and the fps/inference readout keep running. - Anti-contention controls: skip preview/pose emits while minimized; cap OpenCV's thread pool (default 2); optional "Reserve CPU cores" affinity mode (off by default, experimental). Changed - Default yaw: soft-center curve at 3x sensitivity; sensitivity sliders now span 0-5x. - Settings > Performance simplified (inference-downscale spinbox removed, driven by the preset; thread cap not surfaced). - Preview shows an explicit "tracking disabled" banner when toggled off instead of "no face detected". Reworded a wizard tip. Fixed - HIGH process priority never applied on 64-bit Windows (untyped ctypes SetPriorityClass mis-marshalled the handle); now set via psutil. - Shutdown crash: the camera-reader's stop Event shadowed threading.Thread._stop, throwing on every exit and skipping cleanup. Packaging (standalone was broken without these; caught by running the exe) - Bundle mediapipe's libmediapipe.dll: dlopen'd at runtime so Nuitka never bundled it -> tracker init failed in the standalone. - Bundle NPClient64.dll + TrackIR.exe: Nuitka's --include-data-dir skips binaries, so the installed app couldn't deliver tracking to iRacing. - bundled_bin_dir(): detect Nuitka (__compiled__) so it resolves <exe>/resources/bin instead of over-shooting to dist/. - Bump version to 0.2.0 (pyproject, __init__, build/installer defaults). Validated: 158 tests pass, ruff clean, and a from-scratch local install (uninstall + bare machine + fresh installer) runs end-to-end.
The .iss OutputBaseFilename produced -win-x64.exe, but release.yml, build_installer.ps1, the README, and the winget manifest all expect -setup.exe -- so the CI release's upload step (if-no-files-found: error) would have failed to find the artifact. Align the .iss to -setup. Also record the packaging fixes (libmediapipe + NPClient/TrackIR bundling, bundled_bin_dir Nuitka detection) in the changelog.
Two issues that would break the tag-triggered release (never exercised end-to-end before; v0.1.0 was built locally): - release.yml invoked iscc directly, skipping the VC++ redist download. openfov.iss requires redist\vc_redist.x64.exe as a bundled source file (gitignored, ~25 MB), so ISCC would fail on the missing file. Now calls build_installer.ps1, which downloads the redist before compiling. - npclient-vendor/build.ps1 hard-required the triplet-named x86_64-w64-mingw32-gcc, which local WinLibs provides but CI's `choco install mingw` does not (it exposes plain `gcc`). Falls back to `gcc` so the NPClient build works in both environments.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[0.2.0] — Head-tracking feel + game-contention performance
Added
Disabling stops MediaPipe (frees CPU) and snaps the in-game view to
center; re-enabling resumes from the last calibration (no recenter).
Rebindable in Settings → Hotkeys.
diagnostic to measure its CPU cost) while tracking and the fps/inference
readout keep running.
CPU:
while the window is minimized / hidden to tray (tracking + game output
continue).
decode work.
process to the top logical CPUs so MediaPipe stays off the game's
cores. Off by default; experimental.
Changed
(fine control near forward view, fast swing to the apex). Pitch and roll
keep the gentle linear default.
is gone (driven by the preset), and the OpenCV thread cap is not
surfaced.
inference is toggled off, instead of the misleading "no face detected".
Fixed
the
ctypesSetPriorityClasscall mis-marshalled the process handleand failed silently. Now set via
psutil, so OpenFOV runs at HIGH andstops losing scheduler contests with the game's render thread.
'Event' object is not callable): the camera-readerthread's stop Event shadowed
threading.Thread._stop, so every exitthrew and skipped pipeline cleanup. Renamed the attribute.
Packaging
libmediapipe.dll(~27 MB). It's loaded viadlopenat runtime, so Nuitka never saw it and
--include-package-dataskipsDLLs — the standalone imported MediaPipe fine but the tracker failed to
initialize ("Could not find module libmediapipe.dll").
NPClient64.dll+TrackIR.exe. Nuitka's--include-data-dirsilently skips
.dll/.exe, so the installed app couldn't delivertracking to iRacing (the registry pointed at a missing DLL).
bundled_bin_dir()now detects a Nuitka build (__compiled__) so itresolves
<exe>/resources/bininstead of over-shooting todist/.OpenFOV-<ver>-setup.exeto match therelease workflow, the winget manifest, and the docs.
Tests