Add experimental packed and in-place DLSS output
- Tag redirected surfaces as R10G10B10A2 ('R3') as well as RGBA16F ('R2'), and
let the native output kernel store the game's R10G10B10A2 texels itself.
- Import linear, exportable game textures (vkd3d-proton patch 0003) into HIP
so the output kernel writes the game's output texture with no game-side copy.
- Add ID3D12DXVKInteropDeviceD4R3 with GetVulkanLinearImageInfo.
- Gate both paths behind D4R_SHIM_OUTPUT_PACKED and D4R_SHIM_INPLACE, and use
them only for split frames of preset M whose output kernel honours the redirect.
- Convert on the host when a recorded packed frame finds the wrong kernel.
- Give the harness an R10G10B10A2 output, and add D4R_SHIM_SPIN_POLL so
frame timing is not quantised to the poll sleep.
- Document the measured removal of the output copies in performance.md.
This commit is contained in:
1 parent
7c60d53cd0
commit
87365077e0
8 files changed
+469
-22
No files matched your search
@@ -9,7 +9,10 @@ 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)
|
||||
// D4R_SHIM_SPIN_POLL=1 (measurement only): every poll yields instead of sleeping, so frame timings are
|
||||
// not quantised to the ~250 us a 200 us sleep takes. Costs a CPU core per waiting thread.
|
||||
static const bool spin = GetEnvironmentVariableA("D4R_SHIM_SPIN_POLL", nullptr, 0) > 1;
|
||||
if (microseconds == 0 || spin)
|
||||
{
|
||||
SwitchToThread();
|
||||
return;
|
||||
|
||||
Reference in new issue
Block a user