Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
display_issues [2020/02/19 15:47]
lbrpdx
display_issues [2021/01/08 01:39] (current)
lbrpdx
Line 1: Line 1:
 ~~NOTOC~~ ~~NOTOC~~
-===== Display issues, where xrandr is your friend =====+===== Emulation with 4K and ultrawide monitors, or problems when your screen is not fully displayed ===== 
 + 
 +Older 8-bit and 16bit systems, or arcade systems from the 80s and 90s were using 4:3 CRT screens. Modern displays are now 16:9 or wider, and can go up to 4K, i.e. 2160 pixels high (compared to 480 or 546 at the time!). 
 + 
 +Having so many pixels to render on the screen is impactful on the system performance. When you have a 4K screen or an ultra-wide screen, Batocera will limit the resolution by default to HD 1920x1080. It's more than enough to render emulators, even the most recent one. However, when you have an ultra-wide monitor, display is stretched.  
 + 
 +For 4K monitors, because the resolution is by default resized to 1920x1080, you might see a screen that looks like this one - actually it's what 1920x1080 is, centered in a 3840x2160 screen: 
 + 
 +{{ :minihd_in_4k.png?nolink&400 |}} 
 + 
 +In order to cover the whole screen, the best solution is to set the **VIDEO MODE** to 1920x1080 -- you can do that on a system-by-system basis in the **PER SYSTEM ADVANCED CONFIGURATION** screen. 
 + 
 +Another use case is when you have a 1280x720 TV, for example, and you want to use bezels that are designed for 1920x1080. Batocera 5.27 can automatically resize the bezels, but sometimes you need to force the **VIDEO MODE** to take your 1280x720 resolution. 
 + 
 +If you absolutely want to use the 4K resolution for whatever reason (shaders looking better, you have a non-standard wide format on your TV/monitor...), you can force the **STRETCH BEZEL** option too. Same thing, this is something you can do on a system-by-system basis. **WARNING** this has an impact on the emulation performance. 
 + 
 +==== When EmulationStation feels sluggish on a 4K TV==== 
 + 
 +There are some SBC + TV combinations where EmulationStation feels sluggish (default theme seems to be lagging behind, with a refresh rate like 10 FPS). It's really depending on your own configuration, but we have reproduced this with a Raspberry Pi4 and a couple 4K TV models. By default, ES should negotiate with your TV to fix its resolution to 1080p, but sometimes your TV brand doesn't accept it and stays at 4K/2160p resolution. 
 + 
 +To force 1080 in those cases, edit ''batocera.conf'' and add a line: 
 + 
 +  system.es.maxresolution=1920x1080 
 + 
 +This shouldn't be necessary for most TVs, though, and the default mode can be set back with ''es.maxresolution=0'' (or just comment out or remove the line in ''batocera.conf''). 
 + 
 +===== How does that work under the hood? ===== 
 + 
 +You can do it though ES as shown above, but you can also tweak your system with ''batocera.conf'' to make the aspect ratio better. 
 + 
 +1. Know what are the resolutions available on your system + TV combination by entering the command ''batocera-resolution listModes'': 
 + 
 +   # batocera-resolution listModes 
 +   0:2560x1440 60Hz 
 +   1:2560x1080 60Hz 
 +   2:1920x1080 60Hz 
 +   3:1920x1080 60Hz 
 +   4:1920x1080 60Hz 
 +   5:1920x1080 60Hz 
 +   6:1920x1080 60Hz 
 +   7:1920x1080 50Hz 
 +   8:1920x1080 50Hz 
 +   9:1680x1050 60Hz 
 +   10:1600x900 60Hz 
 +   11:1280x1024 75Hz 
 +   12:1280x1024 60Hz 
 +   13:1440x900 60Hz 
 +   14:1280x720 60Hz 
 +   15:1280x720 60Hz 
 +   16:1280x720 50Hz 
 +   17:1024x768 75Hz 
 +   18:1024x768 60Hz 
 +   19:800x600 75Hz 
 +   20:800x600 72Hz 
 +   21:800x600 60Hz 
 +   22:720x576 50Hz 
 +   23:720x576 50Hz 
 +   24:720x480 60Hz 
 +   25:720x480 60Hz 
 +   26:720x480 60Hz 
 +   27:720x480 60Hz 
 +   28:640x480 75Hz 
 +   29:640x480 60Hz 
 +   30:640x480 60Hz 
 +   31:720x400 70Hz 
 + 
 +2. Then, choose the mode from the list that is the one you want to force to RetroArch. For example, if I want to force ''2560x1080'' for the emulators, I can add in my ''batocera.conf'': 
 +   global.videomode=1 
 + 
 +Emulators will then all select mode 1 = 2560x1080 from the list above as their screen resolution. If I want to select a specific resolution only for a specific emulator, I can do that with for instance ''n64.videomode=1''
 + 
 +Batocera 5.27 and later will automatically resize 1920x1080 bezels to ultrawide by adding black borders on the sides. It will also resize full HD 1080 bezels to HD-ready 720p. 
 + 
 +3. EmulationStation ignores this parameter. If you want to put ES in a specific resolution, you need to edit ''/etc/init.d/S31emulationstation'' and add the wanted resolution with a dedicated ''batocera-resolution setMode XX'' line in the script: 
 + 
 +   cd /userdata # es need a PWD 
 +   batocera-resolution setMode 1 
 +   HOME=/userdata/system LANG="${settings_lang}.UTF-8" SDL_NOMOUSE=1 /usr/bin/emulationstation --no-splash & 
 + 
 +Don't forget to ''batocera-save-overlay'' to keep it upon reboot. 
 + 
 +4. If you ask for a 4K 3840x2160 resolution, but with a bezel that is HD 1920x1080, by default Batocera will add black borders around the bezel, like on the picture above. If you want your display to be full screen, you can either: 
 + 
 +  - switch to a lower resolution (like 1920x1080) 
 +  - add a line ''mame.bezel_stretch=1'' in your ''batocera.conf'' for each emulator you want to stretch. Or ''global.bezel_stretch=1'' if you want to enable stretching to your native 4K resolution. **WARNING** this has an impact on the emulation performance. 
 + 
 +===== Display issues, when xrandr is your friend ===== 
 + 
 +**This section is for PC x86 and x86_64, not for SBCs like Raspberry Pi or Odroid.** 
 This tutorial is useful if you have display issues, for instance if you need to rotate your screen, or anything else.\\ This tutorial is useful if you have display issues, for instance if you need to rotate your screen, or anything else.\\
 \\ \\
 For example, I have a 4k UHD TV, Batocera will display the highest display resolution available on my screen, but 4k isn't good for emulation: it's lagging. So, I need to force a smaller resolution.\\ For example, I have a 4k UHD TV, Batocera will display the highest display resolution available on my screen, but 4k isn't good for emulation: it's lagging. So, I need to force a smaller resolution.\\
 \\ \\
-First of all, you need to connect on your Batocera through SSH, let's use Putty for this!\\ +First of all, you need to connect on your Batocera through SSHYou can find a "How to" by following [[access_the_batocera_via_ssh |this link]].
-You can find a "How to" by following [[en:access_the_batocera_via_ssh |this link]].+
  
 Okay, now you're connected on your Batocera, let's begin.\\ Okay, now you're connected on your Batocera, let's begin.\\
  • display_issues.1582123673.txt.gz
  • Last modified: 15 months ago
  • by lbrpdx