Open chinagreenelvis opened 3 months ago
Also, strangely, override corename.switchres.ini files work when a display is connected through a card with CRTEmudriver even when no root-directory INI file exists; a display connected through the main card requires both the root-directory INI file (in order to work at all) and the override INI (in order to work properly).
@alphanu1 @substring Might have some feedback, thank you ;)
There is also this bug where it should look for the file in \ini\ but it doesn't
Taken from swichres readme file
switchres GitHub A default switchres.ini file will be searched in the current working directory, then in .\ini on Windows, ./ini then /etc on Linux.
It definitely requires an .ini file in the root directory at least for my DOS mode switchres to work. Changes to that INI file don't make any difference but the contents of the file still matter because I tried blanking it out and it failed to function when I did.
The whole thing is really tricky at the moment and it's almost a miracle that I have it working at all but I'm glad that I do because having it working is amazing.
Windows 😒 I don't have a windows CRT setup, but I'll do my best.
Could it be that it's just the monitor definition that is not loaded from the .ini in the root dir ?
rgui Main Menu->Settings->Video->CRT SwitchRes
CRT SwitchRes: INI CRT Super Resolution: Native
Retroarch.cfg
crt_switch_resolution = "4"
crt_switch_resolution_super = "0"
With switchres.ini file not present in the root of the Retroarch folder
INFO] [CRT]: Requested Resolution: 256x224@60.099827 orientation: normal
[INFO] [CRT] Video context is: wgl
[INFO] [CRT]: Current running core FCEUmm
[DEBUG] 256x224 rotation: 0 rotated: 0 core rotation:0
[INFO] Switchres: Calculating best video mode for 256x224@60.099827 orientation: normal
[INFO] Switchres: Modeline "800x480_60i 15.656005KHz 60.099827Hz" 16.266589 800 833 909 1039 480 483 489 521 interlace -hsync -vsync
[INFO] set_desktop_mode: \\.\DISPLAY20 (800x480@60) flags(2)
[INFO] sr_set_mode: successfully switched to 800x480@60.099827
[INFO] [CRT]: Setting Aspect Ratio: 1.714286
[INFO] [CRT]: Setting Video Screen Size to: 768x448
[INFO] [Video]: Video refresh rate changed to 60.100 Hz.
Symbolic soft link from C:\ini\switchres.ini
to the root of the Retroarch folder.
INFO] [CRT]: Requested Resolution: 256x224@60.099827 orientation: normal
[INFO] [CRT] Video context is: (null)
[INFO] [CRT]: Current running core FCEUmm
[DEBUG] 256x224 rotation: 0 rotated: 0 core rotation:0
[INFO] Switchres: Calculating best video mode for 256x224@60.099827 orientation: normal
[INFO] Switchres: Modeline "256x224_60 15.625955KHz 60.099827Hz" 5.172191 256 266 290 331 224 233 236 260 -hsync -vsync
[INFO] set_desktop_mode: \\.\DISPLAY20 (256x224@60) flags(0)
[INFO] sr_set_mode: successfully switched to 256x224@60.099827
[INFO] [CRT]: Setting Aspect Ratio: 1.142857
[INFO] [CRT]: Setting Video Screen Size to: 256x224
[INFO] [Video]: Video refresh rate changed to 60.100 Hz.
The ini file should be searched for first in \ini\ but it completely ignores this.
According to Switchres it should search for the file ini file:
A default switchres.ini file will be searched in the current working directory, then in .\ini on Windows, ./ini then /etc on Linux
So If there is no ini file in the RA root folder RA or an override folder it should search for the file in \ini\
But it doesn't...
This is how it works on Linux so shouldn't it be the same on windows? Better to have one main ini file instead of the same file spread across multiple directories.
Description
switchres.ini files only work as core overrides, the contents of the root directory ini file is ignored completely and treated as default values (arcade_15).
Expected behavior
The root directory switchres.ini (placed in the same folder as retroarch.exe) should produce proper results when modified if no core override INI file exists.
Actual behavior
Changes to the root directory switchres.ini make no difference.
Steps to reproduce the bug
I stumbled upon this after struggling to create custom crt_range for my television set and having VMM produce proper modelines but having RetroArch generate nothing but the default arcade_15 preset modelines. I then created an override switchres file for cores and finally RA began producing modelines consistent with VMM. Because I plan on using the same settings for most cores, having to create an override file for each core is less ideal than being able to use one main switchres.ini to handle everything I don't wish to override.
Bisect Results
I haven't tested with previous versions, so I don't know if this behavior was ever consistent with my expectations, maybe I'm misunderstanding how the main .ini file setup works on Windows or it's just still in early stages of implementation.
Version/Commit
Environment information