Replace the enhanced HDR with a port of RenoDX's tone mapper.

The game's ACES tonemap shader gets a GLSL function linked into its SPIR-V where it clamps each channel: the game's SDR result upgraded to the HDR range by luminance and mapped to the display with the RenoDRT curve, exposure, highlights, shadows, contrast, saturation, highlight saturation, blowout, flare and hue correction. The settings reach it as four vec4 the support buffer gains at 1440. The present encode is a port of the swap chain pass: gamma correction, gamut compression, the peak clamp and PQ. Without an HDR10 swapchain the shader gives the game's own SDR picture; native HDR is unchanged.

The menu offers Off, RenoDX and Native, with gamma correction, the tone mapper and its grading rows. The shader build compiles sources marked "keep functions" without optimisation so their functions survive for the splice.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
tangerineturtle1
2026-11-09 06:06:07 -05:00
parent 778c55777d
commit 9e574f84ec
22 changed files with 1865 additions and 793 deletions

View File

@@ -34,7 +34,7 @@ Report problems as issues, following [CONTRIBUTING.md](CONTRIBUTING.md).
- Frame generation with AMD FSR 3.1 (any GPU): a generated frame between every two the game draws, with the HUD kept
out of it, for about twice the frame rate on a fast display; in a window of another shape than the picture, frames
are generated inside the picture only, so the black bars stay clean
- HDR on HDR displays: the game's own native HDR, or an enhanced HDR made from its SDR picture
- HDR on HDR displays: the game's own native HDR, or its SDR picture tone mapped to the display's peak, with exposure, highlights, shadows, contrast, saturation and gamma in the menu
- Every shader prepared when the game is built, and the pipelines met in play built again in the background at each
start, so play does not stop to compile them; a draw that must wait for its pipeline has it built on worker
threads, never on the game's drawing thread