You are not logged in.

#1 2022-04-03 18:50:09

Denharad
Member
Registered: 2015-11-18
Posts: 5

Scale down GUI to only use part of display

I've got a slightly damaged TV that now has about 10% unusable area at right & bottom edges. I thought it would be neat to keep it usable with Linux by scaling down the desktop to the usable parts of the screen.

The TV (Samsung UN55NU7100) does not appear to have on-screen control for shrinking displayed content, only stretching it out. I was able to roughly achieve the desired result with a Windows laptop & AMD graphics to underscan the output, but this loses good display from top & left. Strangely with Intel graphics on Linux, over/underscan is not a supported property of the output. I played around with the xrandr framebuffer, transform & scale options; with transform it seemed possible to shrink my KDE Plasma desktop but then applications would still draw into the bad areas. Framebuffer correctly blanked the desired area, but did not prevent the whole desktop from drawing into them. I'm probably using these tools improperly.

Essentially I need a method of sending a 3840x2160p HDMI signal to the display while having my desktop environment only utilize say 3491x1964 of the output.

Offline

#2 2022-04-03 21:44:25

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: Scale down GUI to only use part of display

xrandr transform is the proper approach, see https://unix.stackexchange.com/question … -intel-gpu and post the command you tried as well as the resulting "xrandr -q"
It's very important to limit the panning as well (well, unless you want to pan into the black area and maintain the original 3840x2160 w/ only a 3491x1964 segment being visible at any given time)

Offline

#3 2022-04-06 05:44:57

Denharad
Member
Registered: 2015-11-18
Posts: 5

Re: Scale down GUI to only use part of display

OK, thanks seth! I'd ignored the panning option as I didn't think it was relevant. I've simplified my command to:

xrandr --output HDMI-2 --scale 1.06 --panning 3840x2160

This seems to work just as I wanted. The mouse cursor is allowed to go "off screen" but windows are constrained. Output is blurrier than the framebuffer changes but behavior seems less problematic. Also I can get away with losing just 6% before running into bad display area. There's still some distracting lines & shimmering in the damaged area, but I think just masking that off with some black tape will be good enough.

My xrandr -q output

Screen 0: minimum 320 x 200, current 3840 x 2160, maximum 16384 x 16384
DP-1 disconnected (normal left inverted right x axis y axis)
HDMI-1 disconnected (normal left inverted right x axis y axis)
HDMI-2 connected primary 3840x2160+0+0 (normal left inverted right x axis y axis) 1872mm x 1053mm panning 3840x2160+0+0
   3840x2160     30.00*+  25.00    24.00    29.97    23.98  
   4096x2160     30.00    25.00    24.00    29.97    23.98  
   1920x1080     60.00    50.00    59.94    30.00    25.00    24.00    29.97    23.98  
   1920x1080i    60.00    50.00    59.94  
   1680x1050     59.88  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.90  
   1366x768      59.79  
   1280x800      59.91  
   1152x864      75.00  
   1280x720      60.00    50.00    59.94  
   1024x768      75.03    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32  
   720x576       50.00  
   720x576i      50.00  
   720x480       60.00    59.94  
   720x480i      60.00    59.94  
   640x480       75.00    72.81    66.67    60.00    59.94  
   720x400       70.08  
DP-2 disconnected (normal left inverted right x axis y axis)

Offline

#4 2022-04-06 14:14:37

seth
Member
Registered: 2012-09-03
Posts: 50,012

Re: Scale down GUI to only use part of display

That doesn't look like

with transform it seemed possible to shrink my KDE Plasma desktop but then applications would still draw into the bad areas. Framebuffer correctly blanked the desired area, but did not prevent the whole desktop from drawing into them.

Does

xrandr --output HDMI-2 --scale-from 3491x1964 --fb 3491x1964 --panning 3491x1964

work as desired?
The blurriness is because you're upscaling the output to 4070x2290 and then panning that.

If this is really the only way you can get it to work, you can use https://aur.archlinux.org/packages/xpointerbarrier-git

Offline

#5 2022-04-06 14:42:28

progandy
Member
Registered: 2012-05-17
Posts: 5,184

Re: Scale down GUI to only use part of display

Maybe you can simple define a new virtual monitor that only covers the good area like this:

xrandr --setmonitor HDMI-2-crop 3610/1760x2030/990+0+0 HDMI-2

Some other options:
https://askubuntu.com/questions/508358/ … l-graphics

Last edited by progandy (2022-04-06 14:47:27)


| alias CUTF='LANG=en_XX.UTF-8@POSIX ' |

Offline

#6 2022-05-01 18:27:52

Denharad
Member
Registered: 2015-11-18
Posts: 5

Re: Scale down GUI to only use part of display

Thanks for the suggestions. I tested both & they didn't appear to work in this configuration. However it's now a moot point as the crack in the LCD propagated leaving me with 20% usable screen space, & no desire to continue using it. It did give me an excuse to tear the backing off & take a look inside though! Thanks again for the help.

Offline

Board footer

Powered by FluxBB