# rankftw/rhi architecture

> Architecture diagram of the GitHub repository rankftw/rhi, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-28). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/rankftw/rhi
- Repository: https://github.com/rankftw/rhi

## Overview

RHI is a Windows game-library manager for installing and maintaining HDR mods, ReShade, upscalers, shader packs, frame limiters, and NVIDIA settings. The main user flow is discover or add games, view per-game controls, then install or configure components in game folders; background update orchestration maintains them afterward. Groups and paths reflect the supplied tree and README. Several service implementations were not sampled, so their internal call wiring is intentionally left out.

Main entry points: [`RenoDXCommander/ViewModels/GameCardViewModel.cs`](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/GameCardViewModel.cs) (Game controls), [`RenoDXCommander/ViewModels/MainViewModel.cs`](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/MainViewModel.cs) (Library view model), [`RenoDXCommander/Services/UpdateOrchestrationService.cs`](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/UpdateOrchestrationService.cs) (Update orchestration), [`RenoDXCommander/MainWindow.xaml.cs`](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/MainWindow.xaml.cs) (Main window)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["App and library"]
  node_window["Main window<br/>[MainWindow.xaml.cs]"]
  node_mainvm["Library view model<br/>[MainViewModel.cs]"]
  node_cardvm["Game controls"]
end

subgraph group_game["Game discovery"]
  node_detection["Library detection"]
  node_library["Game library"]
  node_drop["Dropped game files"]
end

subgraph group_mods["Game modifications"]
  node_installs["Mod installation"]
  node_auxinstall["Auxiliary installs"]
  node_luma["Luma mods<br/>[LumaService.cs]"]
  node_reshade["ReShade updates"]
  node_shaderpacks["Shader packs"]
end

subgraph group_graphics["Graphics management"]
  node_optiscaler["OptiScaler"]
  node_dlss["DLSS management"]
  node_driver["NVIDIA profiles"]
  node_limiters["Frame limiters"]
  node_hdrtoggle["HDR auto-toggle"]
end

subgraph group_updates["Updates and data"]
  node_manifest["Manifest data<br/>[ManifestService.cs]"]
  node_orchestrator["Update orchestration"]
  node_updater["Update service<br/>[UpdateService.cs]"]
end

node_user(("Player"))
node_gamefiles[("Game installation")]
node_stores(("Game stores"))
node_github(("GitHub manifest"))
node_nvidia(("NVIDIA driver"))

node_user -->|"uses"| node_window
node_window -->|"drives"| node_mainvm
node_mainvm -->|"scans"| node_detection
node_detection -.->|"queries"| node_stores
node_mainvm -->|"loads"| node_library
node_user -->|"drops exe"| node_drop
node_drop -->|"adds game"| node_mainvm
node_mainvm -->|"loads data"| node_manifest
node_github -.->|"serves"| node_manifest
node_mainvm -->|"builds cards"| node_cardvm
node_cardvm -->|"installs mods"| node_installs
node_cardvm -->|"deploys components"| node_auxinstall
node_cardvm -->|"manages Luma"| node_luma
node_cardvm -->|"manages ReShade"| node_reshade
node_cardvm -->|"manages packs"| node_shaderpacks
node_cardvm -->|"manages upscaler"| node_optiscaler
node_cardvm -->|"manages versions"| node_dlss
node_cardvm -->|"sets profiles"| node_driver
node_cardvm -->|"deploys limiters"| node_limiters
node_cardvm -->|"toggles HDR"| node_hdrtoggle
node_installs -->|"writes files"| node_gamefiles
node_auxinstall -->|"writes files"| node_gamefiles
node_luma -->|"deploys mods"| node_gamefiles
node_reshade -->|"updates files"| node_gamefiles
node_shaderpacks -->|"deploys shaders"| node_gamefiles
node_optiscaler -->|"deploys files"| node_gamefiles
node_dlss -->|"swaps DLLs"| node_gamefiles
node_driver -->|"writes profiles"| node_nvidia
node_mainvm -->|"checks updates"| node_orchestrator
node_orchestrator -->|"requests updates"| node_updater
node_orchestrator -->|"updates components"| node_gamefiles

click node_window "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/MainWindow.xaml.cs"
click node_mainvm "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/MainViewModel.cs"
click node_cardvm "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/GameCardViewModel.cs"
click node_detection "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/GameDetectionService.cs"
click node_library "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/GameLibraryService.cs"
click node_drop "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/DragDropHandler.Exe.cs"
click node_manifest "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ManifestService.cs"
click node_installs "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ModInstallService.cs"
click node_auxinstall "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/AuxInstallService.cs"
click node_luma "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/LumaService.cs"
click node_reshade "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ReShadeUpdateService.cs"
click node_shaderpacks "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ShaderPackService.cs"
click node_optiscaler "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/OptiScalerService.cs"
click node_dlss "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/DlssStreamlineService.cs"
click node_driver "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/DlssPresetService.cs"
click node_limiters "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/AuxInstallService.cs"
click node_hdrtoggle "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/HdrToggleService.cs"
click node_orchestrator "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/UpdateOrchestrationService.cs"
click node_updater "https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/UpdateService.cs"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_window,node_mainvm,node_cardvm toneBlue
class node_detection,node_library,node_drop,node_gamefiles toneAmber
class node_installs,node_auxinstall,node_luma,node_reshade,node_shaderpacks toneMint
class node_optiscaler,node_dlss,node_driver,node_limiters,node_hdrtoggle toneRose
class node_manifest,node_orchestrator,node_updater,node_user,node_stores,node_github,node_nvidia toneIndigo
```

## Components

### App and library

- [Main window](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/MainWindow.xaml.cs): `RenoDXCommander/MainWindow.xaml.cs`
- [Library view model](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/MainViewModel.cs): `RenoDXCommander/ViewModels/MainViewModel.cs`
- [Game controls](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/ViewModels/GameCardViewModel.cs): `RenoDXCommander/ViewModels/GameCardViewModel.cs`

### Game discovery

- [Library detection](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/GameDetectionService.cs): `RenoDXCommander/Services/GameDetectionService.cs`
- [Game library](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/GameLibraryService.cs): `RenoDXCommander/Services/GameLibraryService.cs`
- [Dropped game files](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/DragDropHandler.Exe.cs): `RenoDXCommander/DragDropHandler.Exe.cs`

### Game modifications

- [Mod installation](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ModInstallService.cs): `RenoDXCommander/Services/ModInstallService.cs`
- [Auxiliary installs](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/AuxInstallService.cs): `RenoDXCommander/Services/AuxInstallService.cs`
- [Luma mods](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/LumaService.cs): `RenoDXCommander/Services/LumaService.cs`
- [ReShade updates](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ReShadeUpdateService.cs): `RenoDXCommander/Services/ReShadeUpdateService.cs`
- [Shader packs](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ShaderPackService.cs): `RenoDXCommander/Services/ShaderPackService.cs`

### Graphics management

- [OptiScaler](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/OptiScalerService.cs): `RenoDXCommander/Services/OptiScalerService.cs`
- [DLSS management](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/DlssStreamlineService.cs): `RenoDXCommander/Services/DlssStreamlineService.cs`
- [NVIDIA profiles](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/DlssPresetService.cs): `RenoDXCommander/Services/DlssPresetService.cs`
- [Frame limiters](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/AuxInstallService.cs): `RenoDXCommander/Services/AuxInstallService.cs`
- [HDR auto-toggle](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/HdrToggleService.cs): `RenoDXCommander/Services/HdrToggleService.cs`

### Updates and data

- [Manifest data](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/ManifestService.cs): `RenoDXCommander/Services/ManifestService.cs`
- [Update orchestration](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/UpdateOrchestrationService.cs): `RenoDXCommander/Services/UpdateOrchestrationService.cs`
- [Update service](https://github.com/rankftw/rhi/blob/main/RenoDXCommander/Services/UpdateService.cs): `RenoDXCommander/Services/UpdateService.cs`

### Other components

- **Player**
- **Game installation**
- **Game stores**
- **GitHub manifest**
- **NVIDIA driver**

## Connections

- Player → Main window: uses
- Main window → Library view model: drives
- Library view model → Library detection: scans
- Library detection → Game stores: queries
- Library view model → Game library: loads
- Player → Dropped game files: drops exe
- Dropped game files → Library view model: adds game
- Library view model → Manifest data: loads data
- GitHub manifest → Manifest data: serves
- Library view model → Game controls: builds cards
- Game controls → Mod installation: installs mods
- Game controls → Auxiliary installs: deploys components
- Game controls → Luma mods: manages Luma
- Game controls → ReShade updates: manages ReShade
- Game controls → Shader packs: manages packs
- Game controls → OptiScaler: manages upscaler
- Game controls → DLSS management: manages versions
- Game controls → NVIDIA profiles: sets profiles
- Game controls → Frame limiters: deploys limiters
- Game controls → HDR auto-toggle: toggles HDR
- Mod installation → Game installation: writes files
- Auxiliary installs → Game installation: writes files
- Luma mods → Game installation: deploys mods
- ReShade updates → Game installation: updates files
- Shader packs → Game installation: deploys shaders
- OptiScaler → Game installation: deploys files
- DLSS management → Game installation: swaps DLLs
- NVIDIA profiles → NVIDIA driver: writes profiles
- Library view model → Update orchestration: checks updates
- Update orchestration → Update service: requests updates
- Update orchestration → Game installation: updates components
