Changing resolution and refresh rate on the fly on the Pi 4 - any news?
-
I'm porting a script I made for the older Pis to the 4, to dynamically change the monitor refresh rate depending on a specific game or system in Retropie.
The main part goes like this:
vcgencmd hdmi_cvt $x_res $y_res $refresh 0 0 0 1
tvservice -e "DMT 87"
fbset -depth 8
fbset -depth 16It's always worked flawlessly on the 3b+, but results in a black screen on the Pi 4. Apparently it can't work anymore due the switch to FKMS. Is there a way to do it on the Pi 4 yet? Or a way to disable FKMS? Emulationstation refuses to launch if I do that in config.txt
-
I'm porting a script I made for the older Pis to the 4, to dynamically change the monitor refresh rate depending on a specific game or system in Retropie.
The main part goes like this:
vcgencmd hdmi_cvt $x_res $y_res $refresh 0 0 0 1
tvservice -e "DMT 87"
fbset -depth 8
fbset -depth 16It's always worked flawlessly on the 3b+, but results in a black screen on the Pi 4. Apparently it can't work anymore due the switch to FKMS. Is there a way to do it on the Pi 4 yet? Or a way to disable FKMS? Emulationstation refuses to launch if I do that in config.txt
-
Please don't double post, it's enough to post your topic in a single category.
-
RetroArch recently merged a change to allow the resolution switching based on custom resolutions ( based on a
hdmi_timings
config ) - 11590.
RetroArch also has an CRT Switch Resolution feature, supporting the KMS/DRM video drivers for the Pi4 is not yet part of it, but it's planned/worked on. -
@mitu I'm very interested to this, i use a crt cab and we miss resolution switching badly , so i've tried adding
crt_switch_timings = "1920 1 152 247 280 240 1 3 7 12 0 0 0 60 0 40860000 1"
in retroarch.cfg , but doesn't seem to do anything useful
Is this supposed to work with vc4-fkms-v3d ?
-
@myzar said in Changing resolution and refresh rate on the fly on the Pi 4 - any news?:
Is this supposed to work with vc4-fkms-v3d ?
I think so, but the change is in RetroArch's master branch and it will be available in version 1.9.1, while RetroPie has 1.8.8.
-
@mitu yeah i know but i've compiled master Built: Dec 3 2020 Version: 1.9.0 Git: db2cd8f , this is newer than the merged commit referred here , should i ask in the pull https://github.com/libretro/RetroArch/pull/11590 if it is going to do anything ?
-
@myzar Make sure you have
video_fullscreen = yes
set also, if that still doesn't work, you can add your log to the PR and ask the author - maybe further configuration is needed.EDIT: you should also make sure you're editing the correct
retroarch.cfg
, the log file doesn't show which one is used. -
@mitu my bad i was using the vulkan driver it doesn't do anything with that, i have switched back to gl and now it does something
[INFO] [DRM]: Connector 0 assigned to monitor index: #1. [INFO] [DRM]: Mode 0: (FIXED_MODE) 320 x 240, 60 Hz [INFO] [GL]: Found GL context: kms [INFO] [GL]: Detecting screen resolution 1920x240. [INFO] [DRM]: custom mode requested: CRT_1920x240_60 [INFO] [EGL] Falling back to eglGetDisplay [INFO] [EGL]: EGL version: 1.4 [INFO] [EGL]: Current context: 0xaa81ffa8. [INFO] [KMS]: New FB: 1920x240 (stride: 7680). [INFO] [GL]: Vendor: Broadcom, Renderer: V3D 4.2. [INFO] [GL]: Version: OpenGL ES 3.1 Mesa 21.0.0-devel (git-872c4bcd27). [INFO] [GL]: Using resolution 1920x240 [INFO] [GL]: Default shader backend found: glsl.
But it's pretending that it switched res it's delusional like fbset , let me try to explain even tho english isn't my native language , it thinks to be @ 1920x240 but it's still drawing @ 320x240 , the result is that everything is super mega giant like you zoomed with a 4x multiplier.
The point is that isn't really switching res , i'm sure because i can put bogus values which my monitor wouldn't be able to sync. Such a shame i was so excited we miss pixel perfects res badly on the rpi4 -
it was too good to be true :( i was right it doesn't work https://github.com/libretro/RetroArch/pull/11590#issuecomment-743402918
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.