Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

 
 

Repository files navigation

ReVIctory

A fork of VIctory, a compatibility layer that runs an Xbox Series title natively on Windows from files you supply yourself. This fork targets AMD RDNA 4 (Radeon RX 9070 XT) and aims for a steady 30 fps first, then for higher frame rates and a correct picture.

This repository contains no game files, code or assets. You need your own copy of the game. The project is not affiliated with or endorsed by the game's developer or publisher.


Status

As of 2026-11-29. Measured on one PC: Ryzen 9 9950X3D, 64 GB RAM, Radeon RX 9070 XT (16 GB), game on an internal NVMe drive, Series X profile (2560×1440 rendered, 3840×2160 output), diag build, default settings.

Frame rate 25–30 fps while driving, capped at 30; dips in the busiest areas
Frame time The thread that prepares the title's work for the card (~25–35 ms) and the card itself (~85–95% busy) are now about equally the limit
Streaming No freezes; textures and models keep up at normal speeds and catch up quickly at high speed
Graphics memory ~80–90% of the budget Windows gives, with headroom kept on purpose
Ray tracing (-RayTracing) Works, ~15 fps; being optimised
FSR FSR 4 or 3.1 upscaling, and frame generation with the HUD kept out of it
Shaders Every shader the title uses translates
Audio Music, effects, TV and phone-call speakers, reverb

Working well: streaming without freezes, TV and phone audio, car lamps, lit interiors and outdoor lighting without ray tracing (a stand-in for the title's traced indirect light), no popping objects, the intro movie playing as it should.

Known issues:

  • Frame rate is not yet a steady 30 everywhere.
  • Ray tracing costs about half the frame rate.
  • A surface can still turn gray for a moment while its texture is swapped. Two fixes made this rarer (2026-11-29); not every cause is found.
  • In some sessions trees and props vanish for single frames. One fault behind it is fixed; the flashes were still recorded after that, so the cause is not settled.
  • Some cars and trucks lose their painted body at certain angles and look black. Being investigated.
  • Frame generation can leave faint ghosts of moving things at low frame rates. FSR 4's ghosts less than 3.1's, but it is given a fixed camera in place of the game's.
  • Interiors lit mainly by visible lamps can look slightly dimmer than intended (raise the lighting stand-in with F7 or in the menu).
  • The first run of a new build stutters until the driver has made its pipelines (see Quick start, step 4).
  • Mouths don't move with speech in cutscenes and conversations (blinks, brows and bodies do); being investigated.

Requirements

  • Windows 10 or 11, x64, a CPU with AVX2
  • A Direct3D 12 GPU with shader model 6.6 and mesh shaders. Developed on an RX 9070 XT (16 GB); other GPUs may work but are not tested here.
  • 32 GB of RAM at the very least; 64 GB recommended
  • Rust (the toolchain version is pinned in rust-toolchain.toml) and the MSVC build tools (Visual Studio Build Tools, "Desktop development with C++")
  • Your own dump of the game

Quick start

  1. Get the code.

    git clone https://github.com/ReTerryDavis/ReVIctory
    cd ReVIctory
    copy victory.example.toml victory.toml

    Edit victory.toml and set [paths].game_dir to your game folder (the folder that holds game_scarlett_master.exe); steps 3 and 4 read the game's shaders from there. Everything the runtime writes goes to %LOCALAPPDATA%\revictory unless you set cache_dir or data_dir (keep them outside this folder).

  2. Build (several minutes the first time, two or three after):

    cargo build --locked --release -p victory
  3. Put target\release\victory.exe into the game's folder and start it. Without arguments it opens the launcher, which needs nothing else next to it: the game is found there, and AMD's FidelityFX DLLs are inside the executable.

  4. Press Translate (minutes; can be stopped and resumed), then Warm used. "Warm all" makes every pipeline ever recorded, about an hour the first time.

  5. Press Play. Defaults: capped at 30 fps, the intro plays, the game's own upscaler.

From the script instead, with a diag build, which logs in detail and is what all measurements are made with:

cargo build --locked --profile diag -p victory --features diagnostics
.\scripts\play.ps1 -Shaders
.\scripts\play.ps1 -WarmAll
.\scripts\play.ps1 -Exe "C:\Games\GTA6\game_scarlett_master.exe" -Log

Use your own executable's path; -Build release plays the release build. The first line printed names the victory.exe it runs.

Run either from a normal account window, not as administrator: the driver then keeps its shader cache in the usual place.

Translate again only when the shader translator changes (the release notes or a commit will say so). Warm again after a new build or a new GPU driver.

Before playing, close what holds the graphics card or a lot of memory (browsers with many tabs, Discord or its hardware acceleration, AMD Chat, screen recorders): Windows gives the game less video memory while they run. Each copy of the game commits about 30 GB of memory, so make sure no earlier copy of victory.exe is still running.

The launcher

victory.exe started without arguments opens a window that does what scripts\play.ps1 does, with the same settings (a test keeps the two alike). What is under the pointer is explained at the bottom; Enter plays, Esc closes.

Part What is in it
Game Where the game is. Found by itself if victory.exe is in its folder
Picture Upscaler and profile, FSR version, frame generation and which FSR makes it, frame cap, Series X or S, borderless, ray tracing
Performance The fast renderer, larger streaming limits and software page table (all recommended), the log
Safe settings, Defaults The first thing to try when something is wrong; everything as recommended
Translate, Warm used, Warm all Shaders and pipelines ahead of time, in a window of their own. Translate and warm before playing does the first two before every start
More Any other setting, VICTORY_NAME=value with ; between several. These win over the rest
Logs Opens %LOCALAPPDATA%\revictory\logs. What the game's process printed is in launcher-output.txt there

The window hides while the game runs and comes back with its exit code. The FSR profile and version, frame generation and the cap are shared with the menu in the game (F1); the rest is kept in %LOCALAPPDATA%\revictory\launcher.txt. All other commands (victory run, shaders, warm, ...) work as before. Settings left over in the environment are not passed on, as with the script.

Script options

scripts\play.ps1 sets everything the fork is played with. By default it turns on -Fast, -Stream and -SoftPages and caps the title at 30 fps, or at what the menu in the game was set to last.

Option What it does
-Exe <path> The game's executable (needed to play)
-Log Writes the log to %LOCALAPPDATA%\revictory\logs\play-<time>….log
-Safe Without the newer, faster ways: the first thing to try when something is wrong
-NoSoftPages The 2026-11-27 11:55 streaming path instead of the software page table (Streaming)
-NoFast, -NoStream Leave out the renderer switches or the raised streaming limits
-RayTracing The title's own ray-traced lighting (Ray tracing)
-Fsr3 quality|balanced|performance AMD's PC FSR 3.1 upscaler (FSR)
-Fsr4K <profile> -FsrVersion 4 FSR 4 where the card has it
-FrameGen With -Fsr3/-Fsr4K: AMD's FSR frame generation
-Borderless Full-screen window without a frame, the picture at its own size in the middle (black sides on a wider screen)
-Build release Runs target\release\victory.exe instead of target\diag
-Victory <path> Runs another victory.exe with the same settings (to compare builds)
-Shaders, -Warm, -WarmAll Prepare shaders and pipelines instead of playing (Quick start)
-StreamLog Also logs every streaming request
-More @{ NAME = 'value' } Any other setting. Settings left over in the terminal are cleared, so use this for them.

Useful settings for -More:

Setting What it does
VICTORY_FRAME_INTERVAL_MS = '0' Uncapped ('16.667' caps at 60); also live in the menu, which keeps it for later runs
VICTORY_FRAMEGEN_VERSION = '3' Frame generation by FSR 3.1 instead of FSR 4
VICTORY_TEXTURES_AT_ONCE = '0', VICTORY_MOVED_LEVELS = '0', VICTORY_SWEEP_FIRST = '0' Turn off the fixes of 2026-11-29 (gray textures, late scene data), to compare
VICTORY_SUBMIT_PREP = '1' Experimental: work prepared when the title submits it. No gain measured yet
VICTORY_AMBIENT = '0' Turns off the lighting stand-in (the title's own indirect light only)
VICTORY_REFLECT_STANDIN = '0' Turns off the reflection stand-in
VICTORY_STARTUP_CARD = '1' Shows the startup progress card (off by default)
VICTORY_KBM_GTA = '1' PC-style keyboard and mouse on the stand-in pad: F2 or ` toggles mouse look. Sensitivity: VICTORY_MOUSE_SENS; invert: VICTORY_MOUSE_INVERT_Y = '1'
VICTORY_D3D12_ADAPTER = 'NVIDIA' Picks a GPU by index or part of its name (hybrid-graphics PCs)

Every VICTORY_… setting is described in a comment where the code reads it.

The portable scripts

scripts\portable is the older way without the source code (the launcher in victory.exe does all of it): put victory.exe and the three victory-*.cmd files next to the game's executable.

File Use
victory-play.cmd Starts the game with the same defaults as play.ps1. Add words in any order: fsr3 (or fsr4), balanced/performance, framegen, borderless, raytracing, nosoftpages
victory-shaders.cmd Translates the shaders and makes the pipelines ahead
victory-settings.cmd The settings both use; also where the FSR DLL folder is set

Logs go to victory-logs\ next to the game.

The in-game overlay

F3 shows the HUD: frame rate, frame time (with the p90 and the longest), GPU busy, the submit thread's time, graphics memory (amber past the point where new textures stop, so above 93% by default), late command lists and, while there are any, pipelines being compiled.

F1 opens the menu; F1 or Esc closes it. While it is open the game gets no input and the cursor shows. Q and E change tabs. The panel at the right describes the setting in focus.

Tab What is in it
Performance Frame rate and its history, the frame's steps, command translators, CPU, video memory and RAM, the texture queue, pipelines and caches
Game Settings Upscaling and frame generation, then the game's own quality levels
Lighting The indirect light stand-in, crease shading and indoor reflections. F6/F7 lower or raise the light, F8 turns crease shading on or off, F9 goes back to the run's start
Runtime Frame pacing (with 30, 40, 60 fps and uncapped buttons), texture, pipeline and overlay switches, and the run's VICTORY_… variables
Tools Write the counters or the video memory breakdown to the log, save the pipeline library and, in a diag build started with VICTORY_RECORD, capture a frame
Cheats Only once turned on, see below

Game Settings. Change one or more quality levels, then press Apply; Revert drops changes not applied yet and Restore all goes back to the run's start. The game takes them when its own settings update runs, which in play it may not do for a long time: Force apply shows while a change waits.

Cheats (story mode). Turn the tab on under Runtime → Overlay & Interface → "Cheats tab", or with VICTORY_CHEATS=1: heal, god mode, about $100,000, the wanted level, vehicle repair, weather, time of day and eight of the game's dormant cheat vehicles (numbered: their names are not in its code). Each calls the game's own function, whose code is compared first; one that differs is shown as unavailable. God mode refills health, so a hit that kills at once still kills. Armour and infinite ammo are not offered. No cheat has been confirmed to work in a logged run yet (2026-11-28).

Menu choices are saved in %LOCALAPPDATA%\revictory\overlay.txt.

AMD FSR upscaling and frame generation

The game's own upscaler is used by default. AMD's PC FidelityFX can replace it, and can also make a frame between each two of the game's (frame generation).

The DLLs come with the repository in bin\fidelityfx-2.4.0, from AMD's FidelityFX SDK 2.4.0 (Kits/FidelityFX/signedbin, MIT licence):

  • amd_fidelityfx_loader_dx12.dll
  • amd_fidelityfx_upscaler_dx12.dll
  • amd_fidelityfx_framegeneration_dx12.dll (frame generation)

play.ps1 uses that folder by itself, and victory.exe has copies in it, which the launcher writes to %LOCALAPPDATA%\revictory\fidelityfx-2.4.0. To use others, name their folder with VICTORY_FIDELITYFX_DIR or fidelityfx_dir in victory.toml (either one wins), or put them into a fidelityfx folder next to victory.exe. The portable scripts set the folder in victory-settings.cmd.

Choose a profile in the launcher, or with the script:

.\scripts\play.ps1 -Exe <exe> -Log -Fsr3 quality
.\scripts\play.ps1 -Exe <exe> -Log -Fsr3 quality -FrameGen
Profile The game renders Output
quality 2560×1440 3840×2160
balanced 2258×1270 3840×2160
performance 1920×1080 3840×2160

Version: -Fsr3 uses the newest FSR 3.1 the DLL offers, even on a card with FSR 4. -Fsr4K <profile> -FsrVersion 4 uses FSR 4.1.2 where AMD's SDK offers it for the card, FSR 3.1 otherwise. The log names the version it picked ("selected PC upscaler").

What changes while playing (F1 → Game Settings, and Runtime for the cap), in a run started with the PC upscaler:

Setting Changes
Frame generation on or off At once
FSR 3.1 or 4 At once, with a short hitch; about 350 MB more while both exist
Frame cap At once, the game's own limiter and time step with it; kept for later runs
Profile, or the upscaler on or off At the next start: the game sizes its textures by it when it starts

What the menu saves applies to the next start unless the script names something else (-Fsr3, -Fsr4K). To go back to the game's own upscaler, choose it in the launcher or delete the fsr_ lines in %LOCALAPPDATA%\revictory\overlay.txt. The live FSR version and cap are new (2026-11-29) and little tested.

Graphics memory: about 0.65 GB more was measured with quality and frame generation. It is counted in the budget by itself. On a 16 GB card, watch the overlay's memory line; Windows' budget shrinks while other programs hold the card.

Frame rate: a lower profile frees up the card. Where the processor is the limit, as it is in most busy places now, the frame rate stays the same.

Frame generation:

  • Needs -Fsr3 or -Fsr4K (it takes the PC upscaler's depth and motion vectors) and the frame-generation DLL; without the DLL the log names the file and the run only upscales.
  • Made by FSR 4 where the card has it, otherwise by 3.1 (VICTORY_FRAMEGEN_VERSION=3: always). VICTORY_FRAMEGEN_DEBUG=1 shows AMD's debug view.
  • The game's HUD is kept out of interpolation (VICTORY_FRAMEGEN_HUDLESS, on), so text and the minimap don't smear.
  • It adds about one frame of latency.
  • For even pacing, cap the game at half the display's refresh, e.g. -More @{ VICTORY_FRAME_INTERVAL_MS = '16.667' } on 120 Hz (the default cap is 30).
  • The overlay shows presented frames and, below them, the game's real frames.

Streaming

Two streaming implementations are built in, chosen once at start (docs/streaming-paths.md):

  • Software page table (default). On the console the title remaps 64 KiB memory pages while it streams. Doing that with Windows calls cost up to 2 ms per page and caused the freezes. This path keeps the remaps in a table of its own and maps a page only when it is touched. One rule keeps every GPU copy and texture in step with what the pages hold; it is written down in docs/xbox-api-notes.md ("The soft page table's invariant"). Streaming requests are also served oldest batch first, which matches the order the title retires them in.
  • 11:55 path (-NoSoftPages). The streaming code of the 2026-11-27 11:55 build, which also streamed well without the table. It is kept as a fallback.

Graphics memory

The layer keeps a GPU copy of what the title streams in, so the card can fill up. The policy (docs/xbox-api-notes.md, residency section):

  1. Evict above 85% of the budget Windows reports, load up to 93%, and react when that budget changes. The gap is what lets textures load while others are let go (VICTORY_VRAM_GAP; 0: both at 90%).
  2. Fewer detail levels for new textures above 89%. Full detail returns once there is room again.
  3. Small textures are still made when the card is full, in the gaps of existing texture blocks.
  4. Idle textures are evicted before anything is refused, and half-empty texture blocks are repacked so whole blocks can be released.
  5. A slot never shows another texture's data, nor black. It shows a neutral gray until its own texture is ready (VICTORY_WAIT_STANDIN; textures of numbers rather than colors, such as depths and heights, read zero).

Other programs using the GPU (browsers, chat apps) take from the same budget. Closing them gives the game more room.

Ray tracing

-RayTracing turns on the title's own ray-traced lighting, reflections and global illumination. The console's acceleration structures are rebuilt and traversed in the layer (docs/fork-ray-tracing.md, docs/ray-tracing-cost.md). It currently halves the frame rate.

Without it, a stand-in fills in the indirect light and reflections the title would trace (VICTORY_AMBIENT, VICTORY_REFLECT_STANDIN):

  • it leaves light alone where the game already got it right, such as outdoor sky light;
  • it fills in where the game's result is missing, such as dark interiors;
  • a few bright lights cannot pump the whole scene.

Logs, profiles, captures and troubleshooting

What Where
Run logs (-Log) %LOCALAPPDATA%\revictory\logs\play-*.log
The runtime's crash records %LOCALAPPDATA%\revictory\data\<title id>\crashes.log
The runtime's minidumps (every thread; on a crash, and after 20 s without a frame: VICTORY_HANG_DUMP, VICTORY_DUMP=0|full) %LOCALAPPDATA%\revictory\data\<title id>\dumps\
Menu settings %LOCALAPPDATA%\revictory\overlay.txt
Shader and pipeline caches cache_dir in victory.toml (default %LOCALAPPDATA%\revictory\cache)

Something is wrong:

  1. Try -Safe.
  2. Try -NoSoftPages.
  3. Delete overlay.txt to drop saved menu choices.
  4. Keep the log; it names the setting behind most lines.

Clearing the shader cache is not needed. Translations are stored per translator version and settings, so an old build never picks up a new build's shaders or the other way round.

Frame captures for the replayer (docs/replay.md):

  1. Delete any old D:\victory-captures\go. Clear out old capture-<n> folders now, not while the game runs: each run makes its folder at launch and records shaders into it.
  2. Launch with -More @{ VICTORY_RECORD = 'D:\victory-captures'; VICTORY_RECORD_FRAMES = '1' }.
  3. When the moment is on screen, run New-Item D:\victory-captures\go (or press the button in the menu's Tools tab; either way delete go before the next launch). The game pauses a few seconds while it writes about 7 GB. In a cutscene it can take about 3 s longer to start (it waits up to 100 frames for one whose lists were all recorded).

victory replay <folder> --pixel x,y then traces any pixel back through every draw. This found the car-lamp flicker and the black walls.

Frame recordings (diag builds), for what shows for a frame only: F11 starts one and F11 again ends it. It is written to %LOCALAPPDATA%\revictory\captures with each frame's picture, what ran in it and what happened meanwhile. VICTORY_REC_GB sets how much memory it may hold (4).

Profiles: -More @{ VICTORY_PROFILE = '<from s>,<to s>,<ms>,<file>' } samples the busiest threads' stacks. Keep target\diag\victory.pdb from the same build to read it.

How it works

The layer loads the title's executable, answers its system calls (Xbox OS, Xbox Live offline, DirectStorage, audio) and translates its graphics:

  • Console D3D12.X becomes PC Direct3D 12 (crates/victory-gpu). The title's command lists are written down on its own threads and translated by twelve threads of ours. A submit thread joins the title's submissions, copies what the CPU changed in shared memory to the card, and brings back what shaders wrote.
  • RDNA 2 shaders become DXIL (crates/victory-shader), ahead of time and into a versioned cache.
  • Load-time patches (crates/victory-loader), each byte-checked against the title's code and switchable: larger constant and streaming rings, the descriptor writes reported to us, the frame-rate setting, the settings menu.
  • Runtime services (crates/victory-hle): memory and page mapping, DirectStorage, audio DSP, input, saves.
  • The Xbox GDK headers installed locally were used as the reference for the console's API. Every constant, structure and function slot was compared against it, and the results are recorded in docs/xbox-api-notes.md. Nothing from the GDK is in this repository.

Documentation

File About
docs/architecture.md How the crates fit together
docs/streaming-paths.md The two streaming paths
docs/xbox-api-notes.md The GDK audits; the soft page table's invariant; residency
docs/replay.md Recording and replaying a frame
docs/card-time.md Where the GPU's time goes
docs/fork-ray-tracing.md, docs/ray-tracing-cost.md Ray tracing and the lighting stand-in
docs/title-patch-candidates.md Title-side patches: done, measured, candidates
docs/title-menus.md The title's menus and settings
docs/shader-status.md Shader translation census
docs/findings.md What was learned on the RX 7900 XTX fork this one came from
docs/README-fxceless.md Upstream commands and debugging switches
docs/asset-policy.md What may and may not be in the repository

Credits

This is a tree of other people's work with more on top. The history is kept, and commits taken from elsewhere name the commit and its author.

  • VIctory by Marvisak and its contributors: the loader, the runtime services, the Direct3D 12 back end and the shader recompiler.
  • fxceless/victory-fork: the fork this line started from, and the people whose pull requests it carries.
  • VIctory on an RX 7900 XTX: the porting approach, renderer patches and much of the submit pipeline this fork builds on.
  • DexNom/VIctory: ray tracing fixes, cube gradients, sparse textures, the title profile and the PC FidelityFX bridge.
  • Belobug/VIctory-Belobug-AMD: the ambient light idea, pipeline workers, and work by romainhedouin.
  • FQY55kai/ZJOU-VICTORY.
  • myokex/victory-amd: the guard over every view of a page (with Spexivus, joroyt and tightfall), and Joshua Odom's reads into title memory.
  • Geckomacabre and cxy0072019-sketch: the texture read-back.
  • XCL (GPL-2.0-only) was read for how the same title behaves under another layer; no code of it is here.
  • This fork's changes were made with Claude Code.

License

GPL-3.0-or-later, as VIctory. See LICENSE; the one file that is not covered is named in docs/asset-policy.md.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages