d39da4bc06
P1 done: a pure-Rust UMDF2 IddCx driver, drop-in compatible with the host's
existing vdisplay/sudovda.rs control plane (the {e5bcc234} interface + the
SudoVDA IOCTL ABI), so the host drives it unchanged. Validated streaming on
glass at 5120x1440@240 — steady 240 fps, ~2.4 ms encode, clean teardown, full
parity with SudoVDA.
- Vendored wdf-umdf-sys / wdf-umdf bindgen crates (MIT, from virtual-display-rs)
+ the SDK-version build.rs fix that resolves the IddCxStub lib path by the WDK
version actually containing um\x64\iddcx, not the max base SDK.
- pf-vdisplay crate: entry/callbacks/context/control/monitor/edid/
swap_chain_processor. Our OWN 128-byte EDID (manufacturer PNK, product
punktfunk — no SudoVDA bytes), a real swap-chain drain (faithful vdd port,
required so DWM keeps compositing), the SudoVDA-compatible IOCTL control plane
(ADD/REMOVE/PING/GET_WATCHDOG/GET_VERSION/SET_RENDER_ADAPTER) + a watchdog that
tears down orphaned monitors when the host stops pinging.
- deploy-dev.ps1: stage + sign + stampinf (date.time DriverVer) + Inf2Cat +
install, codifying the "bump DriverVer or pnputil keeps the old binary" gotcha.
- docs/windows-virtual-display-rust-port.md: investigation, the on-glass
validation, and the two traps that cost time (Session-0 measurement +
accumulated device-state needing a reboot).
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
31 lines
680 B
Rust
31 lines
680 B
Rust
mod iddcx;
|
|
mod wdf;
|
|
|
|
use std::any::Any;
|
|
|
|
pub use paste::paste;
|
|
|
|
pub use iddcx::*;
|
|
pub use wdf::*;
|
|
pub use wdf_umdf_sys;
|
|
|
|
use wdf_umdf_sys::NTSTATUS;
|
|
|
|
/// Used for the macros so they can correctly convert a functions result
|
|
fn is_nt_error(val: &dyn Any, other_is_error: bool) -> bool {
|
|
if let Some(status) = val.downcast_ref::<NTSTATUS>() {
|
|
return !status.is_success();
|
|
}
|
|
|
|
// other errors which may not be error codes, but may also be
|
|
// such as HRESULT == i32
|
|
if other_is_error {
|
|
if let Some(status) = val.downcast_ref::<i32>() {
|
|
let status = NTSTATUS(*status);
|
|
return !status.is_success();
|
|
}
|
|
}
|
|
|
|
false
|
|
}
|