Add experimental preset L and fix DLSS resource lifetimes and waits
- Build L texture variants and complete older release kernel bundles. - Add selective Swin encoder fallback to reduce L/M motion trails. - Add opt-in GPU motion-vector dilation for thin geometry and sky gaps. - Replace GPU input waits with cancellable readiness polling and use sleeping event queries for completion. - Retain recorded resources through command allocator completion, defer shutdown until cleanup, and preserve unfinished output synchronization. - Extend lifecycle harness checks and add event, model and motion tests. - Update configuration defaults, build scripts and release documentation.
This commit is contained in:
1 parent
b645ef9096
commit
f66cccaf28
32 files changed
+1362
-249
No files matched your search
@@ -0,0 +1,23 @@
|
||||
#pragma once
|
||||
#include <windows.h>
|
||||
#include <cstdint>
|
||||
|
||||
// MinGW's Win32 std::sleep_for can truncate submillisecond durations to zero.
|
||||
// NtDelayExecution retains 100 ns precision and actually sleeps under Wine.
|
||||
inline void d4r_sleep_us(unsigned int microseconds)
|
||||
{
|
||||
using Delay = LONG(WINAPI*)(BOOLEAN, LARGE_INTEGER*);
|
||||
static const auto delay = reinterpret_cast<Delay>(reinterpret_cast<void*>(
|
||||
GetProcAddress(GetModuleHandleW(L"ntdll.dll"), "NtDelayExecution")));
|
||||
if (microseconds == 0)
|
||||
{
|
||||
SwitchToThread();
|
||||
return;
|
||||
}
|
||||
LARGE_INTEGER interval;
|
||||
interval.QuadPart = -static_cast<LONGLONG>(microseconds) * 10;
|
||||
if (delay != nullptr && delay(FALSE, &interval) >= 0)
|
||||
return;
|
||||
// A rounded-up millisecond wait still releases the CPU if ntdll is absent.
|
||||
Sleep(static_cast<DWORD>((static_cast<uint64_t>(microseconds) + 999) / 1000));
|
||||
}
|
||||
Reference in new issue
Block a user