gpu, hle: AMD frame generation on the host-upscaled frames (VICTORY_FIDELITYFX_FRAMEGEN) #68
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/lobomfz--VIctory-xmem!68
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-68"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@coil111 on GitHub · 2026-12-01 13:44 UTC · original
coil111:fidelityfx-framegen→main· +1198 −13 · 9 files · 1 commits · closed without mergingOff by default. With
VICTORY_FSR_4KandVICTORY_FIDELITYFX_FRAMEGEN=1, the presenter's swap chain is AMD's frame generation proxy, and every frame the title renders gets a generated one in between. In play it makes the game much smoother.How
amd_fidelityfx_framegeneration_dx12.dllfrom the FidelityFX SDK v2.4.0signedbin, the same release./setup.sh fsr4already pins for the upscaler;fsr4now fetches it too (sha256 pinned). Its built-in 3.x provider is selected by version, so no driver ML path is needed.record_dispatch) passes its depth, motion vectors and constants (jitter, motion-vector scale, frame time, reset, camera) to the next present throughRecording::frame_generation_inputs. The present prepares the generator in its own list.aheadslots carry them), and a generator is only replaced (new size or flags) after the presents that name it have settled.HostList::move_copyis split out oftransitionfor this: it moves a held host copy without its title resource.Interface and F3 panel
Interpolated together with the scene, the HUD shakes against the world (it moves with the scene's motion vectors in every generated frame), and the F3 panel is interpolated too.
When the title presents its interface on a plane of its own, this keeps both out of the interpolation: the scene alone goes to the swap chain; the interface plane is copied each frame into a texture of ours (in a fixed state, so whatever state the title left its plane in does not matter), the F3 panel is drawn into it, and the plane is registered with the proxy (premultiplied alpha, like
compose; double buffered, since the title redraws its plane while the proxy still composes it). The proxy then composes it over every real and generated frame. The panel stays above the HUD, as it is without frame generation.With one plane (current
mainatVICTORY_FSR_4K), the interface stays in the scene and is interpolated with it. #63 gives the title its separate plane; with the small addition proposed there (the plane on the FSR 4K path too), the HUD and panel stay still.The panel badge shows
FG:OFF/FG:IDLE/FG:ONin place of the fixedFG:OFF.Tested
RX 9070 XT, Ryzen 7 9800X3D, Gentoo Linux 7.3.4, Wine 11.22, Series X,
VICTORY_FSR_4K=performance(1920x1080 render to 3840x2160):proxy swap chain provider="3.1.7",generator for the upscaled frames provider="3.1.6",generated frames;VICTORY_UI_PLANE=3840x2160):the interface plane is composed over every frame; HUD and panel steady, panel above the healthbar;cargo clippyclean in the touched files;framegenunit tests pass under Wine (2: no DLL keeps it off; the built-in 3.x providers are picked).Known artifacts
At the base frame rates this runs at today (about 18–30 fps at 4K performance, lower while driving), the analytical generator shows its usual weak spots:
AMD's debug view (dispatch flag
FFX_FRAMEGENERATION_FLAG_DRAW_DEBUG_VIEW) shows the inputs are right: the vehicle has no motion on screen, the road expands from the centre, and depth matches the scene. Only the uncovered areas are flagged, and the artifacts are there. A frame-pairing check over a driving session found every upscale's inputs reaching its own present. The artifacts shrink as the base frame rate rises; ML frame generation (see below) is the better fix for them.Not covered
ML frame generation (FSR "Redstone", generator 4.0.2 through the driver's provider) is left for a follow-up PR. It shares this PR's plumbing (same DLL, proxy swap chain, present path) but differs where it matters:
MLFG_UPGRADE), with the sameamdxcffx64.dll4.1.1 andamdxc64.dllbridge that./setup.sh fsr4installs, but the driver reportedly offers it only when the prefix reports Windows 11 (this repo's prefix reports Windows 10 today).The plan is a separate PR on top of this one: the camera-pose read, the driver-provider path behind
VICTORY_FIDELITYFX_FRAMEGEN=4, and a Windows 11 prefix. Mode1stays as it is.RGBA8 swap chains only (what Series X and the two-plane path present).
The interface plane must match the output size; otherwise it is composed into the scene as before (logged once).
@Mylloon on GitHub · 2026-12-01 23:58 UTC · original
Heads up, resolve conflicts please!
@coil111 on GitHub · 2026-12-02 07:13 UTC · original
upd:
merged via train
b76f277/ #83closing. ml gen soon.
Pull request closed