From d9e4627e60b00e36573720d1a734ff4cf6873c7d Mon Sep 17 00:00:00 2001 From: woutermans Date: Wed, 14 Oct 2026 20:50:35 +0200 Subject: [PATCH] release: install.sh accepts any y/n answer, and a non-terminal install builds the engine models ask() takes the default on Enter or EOF, ignores whitespace, accepts any answer starting with y or n and re-asks otherwise. Without a terminal (or with --yes) DO_ENGINE defaults to building the models. RELEASE_NOTES.md: the install.sh engine setup, [Engine] Enabled = auto, and the FSR Ray Regeneration backend that this build does not carry. --- install.sh | 11 +++++++---- packaging/RELEASE_NOTES.md | 4 ++++ 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/install.sh b/install.sh index e6bc86e..72edc46 100755 --- a/install.sh +++ b/install.sh @@ -52,15 +52,17 @@ CACHE="${D4R_CACHE_DIR:-${XDG_CACHE_HOME:-$HOME/.cache}/d4r}" # Questions only on a terminal; otherwise (or with --yes) every default applies. interactive() { (( YES == 0 )) && [[ -t 0 && -t 1 ]]; } -ask() { # ask "QUESTION" DEFAULT(y|n): 0 for yes +ask() { # ask "QUESTION" DEFAULT(y|n): 0 for yes. Enter takes the default; any answer starting with y or n counts. local answer if ! interactive; then [[ $2 == y ]]; return; fi while true; do - read -r -p "$1 [$([[ $2 == y ]] && echo Y/n || echo y/N)] " answer || answer='' + read -r -p "$1 [$([[ $2 == y ]] && echo Y/n || echo y/N)] " answer || { echo; answer=''; } + answer="${answer//[[:space:]]/}" case "${answer,,}" in '') [[ $2 == y ]]; return ;; - y|yes) return 0 ;; - n|no) return 1 ;; + y*) return 0 ;; + n*) return 1 ;; + *) echo ' Please answer y or n (or press Enter for the default).' ;; esac done } @@ -182,6 +184,7 @@ if (( REBUILD == 0 )) && [[ "$DO_ENGINE" != 0 && -f "$STAMP" && "$(cat "$STAMP") echo 'The engine models in this folder are up to date.' done_msg; exit 0 fi +if [[ "$DO_ENGINE" == ask ]] && ! interactive; then DO_ENGINE=1; fi if [[ "$DO_ENGINE" == ask ]]; then echo echo "Set up d4r's own DLSS engine (recommended)?" diff --git a/packaging/RELEASE_NOTES.md b/packaging/RELEASE_NOTES.md index da741e8..d8962e4 100644 --- a/packaging/RELEASE_NOTES.md +++ b/packaging/RELEASE_NOTES.md @@ -1,6 +1,10 @@ # Unreleased +- `install.sh` sets up the native engine: after the NVIDIA DLLs (now also DLSS Ray Reconstruction 310.9.1) it offers to build the engine's models on the user's machine (`d4r/tools/build-engine-models.sh`): Ray Reconstruction D, E and F straight from `nvngx_dlssd.dll`, Super Resolution K, M and L (and their LDR variants) from one test frame per model rendered through d4r under GE-Proton. The verified DLLs and the built models are kept in `~/.cache/d4r`, so the next game's install neither downloads nor builds again. Questions replace the old command-line choices (`--help` lists options for scripted installs). +- `[Engine] Enabled = auto` is the new default: the engine (the faster path) runs whenever `d4r/engine` holds its models, with the fastest model builds; anything it cannot run still uses the CUDA backend. +- Not in this build: the experimental AMD FSR Ray Regeneration backend for Ray Reconstruction (`[RayReconstruction] Backend = fsr`) that an earlier nightly carried. Its code is not part of d4r's sources; Ray Reconstruction runs on NVIDIA's DLSS denoiser (engine or CUDA backend). + - ASI setup ignores Proton accessibility helpers and other background utilities, and serializes setup per plugin installation. Its D3D12 configuration uses regular Windows library hooks and disables Agility SDK upgrades. Game-specific startup remains a separate runtime check. - ASI setup now finds the INI beside the active OptiScaler loader, including GE-Proton's `system32/umu` installation. Missing-file errors identify the actual missing path, and INI updates are staged beside their destination even when the game and prefix are on different filesystems.