Port the v0.5.3 Windows fixes to dev - #462
Merged
Merged
Conversation
…vider on Windows
AI tracking during file export was silently running on CPU instead of
GPU: ort_session.rs tries DirectML first and logs "ORT: DirectML
execution provider enabled" regardless of outcome, masking the real
`ort::ep` warning ("Couldn't register DmlExecutionProvider... its
corresponding Cargo feature is not enabled") logged separately by the
ort crate itself. Root cause: the `ort` dependency never had its
`directml` feature turned on anywhere in the workspace, so the native
DirectML backend was never compiled in - CPU-bound inference every N
frames then stalled the whole stitch/encode pipeline between detections,
which read as "GPU not fully utilized" during export.
Added a `directml` feature through the existing per-backend forwarding
chain (mirrors cuda/tensorrt/coreml): reco-detect -> reco-autocam ->
reco-gui, enabled only for Windows via a target-specific dependency
override so non-Windows builds are unaffected.
Verified with a headless RECO_AUTOLOAD/RECO_AUTOEXPORT test export: log
now shows `ort::ep: Successfully registered 'DmlExecutionProvider'`
(previously a WARN), and nvidia-smi sampling during export went from
bursty 2%<->99% GPU utilization to a sustained 21-60%.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…-core's backend policy rig-calib crashed on startup on a Windows laptop with a broken/partial Vulkan loader (`ReadDataFilesInRegistry` layer-manifest failures): debug builds enable wgpu's DEBUG instance flag, and when Slint's auto-selected Vulkan backend couldn't resolve `vkCmdBeginDebugUtilsLabelEXT`, ash panicked across an FFI boundary that can't unwind, aborting the process. reco-core's own `GpuContext::select_backends()` already avoids this class of bug by preferring DX12 on Windows (a prior fix for AMD Vulkan driver crashes during instance creation), but that policy only applied to the `wgpu::Instance` reco-core creates itself for headless consumers - reco-gui and rig-calib instead hand instance creation off to Slint (`BackendSelector::require_wgpu_28`), which was left to its own Vulkan-first default. Made `select_backends()` public and pass it as `WGPUConfiguration::Automatic::backends` in both, so the shared Slint-owned instance follows the same (still `WGPU_BACKEND`-overridable) policy. Verified: rebuilt and ran rig-calib on the affected laptop - no more Vulkan warnings or panic. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
reco-obs never built on Windows before (only ever exercised on Linux/ macOS), and hit two real bugs once actually tried against libobs 30.0.2 headers with OBS_INCLUDE_DIR set: - bindgen's clang runs in MSVC-compatibility mode on Windows, which is needed for the rest of the libobs/Windows headers to parse, but flips `util/util_uint64.h` into a branch calling the MSVC-only `_udiv128` intrinsic - not declared by clang's own `intrin.h` shim, so parsing failed. Shimmed just that call away via a targeted clang macro rather than dropping MSVC-compat mode (which broke clang's own SSE/SSE2 intrinsic headers when tried). - `blog_shim.c`'s `#include <obs/util/base.h>` silently relied on `/usr/include` being a default compiler search path on Linux/macOS to resolve the Debian libobs-dev `.../obs/` layout; Windows has no such default. build.rs now also adds the parent of OBS_INCLUDE_DIR to the shim's include path when the layout matches that convention. Both fixes are no-ops on Linux/macOS. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Ports the three Windows fixes that shipped in v0.5.3 (cherry-picked from #422, authorship preserved): DirectML execution provider compiled in for Windows builds, Slint's shared wgpu instance follows reco-core's backend policy, and the reco-obs build.rs portability fixes.