Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scaling issue with nvidia gpu and gdm3? #16

Open
cjchristopher opened this issue Feb 3, 2023 · 6 comments
Open

Scaling issue with nvidia gpu and gdm3? #16

cjchristopher opened this issue Feb 3, 2023 · 6 comments

Comments

@cjchristopher
Copy link

cjchristopher commented Feb 3, 2023

  • xrandr-extend version: 0.3.0
  • Python version: 3.10.6
  • Operating System: Ubuntu 22.04.1 gdm3

Description

External HDMI has 4x zoomed (i.e. I can only see the top left corner of a theoretical secondary 3840x2160)

What I Did

pip install xrandr-extend
python3 -m xrandr_extend.cfg

Edited ~/.config/xrandr-extend.cfg as follows:
set primary = 3840, 2160 in [resolutions]
added: [nvidia-g0] as a provider after being instructed by xrandr-extend hdmi with primary = eDP-1 and hdmi = HDMI-1-0

> xrandr-extend hdmi
xrandr --auto
xrandr --listmonitors
xrandr --output eDP-1 --auto --output HDMI-1-0 --auto --scale 2.0x2.0 --right-of eDP-1
Monitors: 2
 0: +*eDP-1 3840/344x2160/194+0+0  eDP-1
 1: +HDMI-1-0 3840/531x2160/299+3840+0  HDMI-1-0

Running with -x 1 hdmi gives me a properly fixed window 1920x1080, but UI elements are all scaled to twice the size (i.e. enormous). A note that UI elements seem to be 2x scaled on the primary 4k laptop display, which is what I want, as without 2x UI scaling there, everything is impossibly small.
Essentially I want: primary to be at 4k with 2x UI scaling, secondary to be at 1080p with 1x UI scaling.

@ashwinvis
Copy link
Owner

Have you tested fractional scaling? For example 1.5?

@ashwinvis
Copy link
Owner

You can also test the --pan option.

@cjchristopher
Copy link
Author

No dice with either/both. Fractional scaling still has the same problems (primary looks fine, secondary just upper right corner), and --pan fails outright with:

BadMatch (invalid parameter attributes)
   Major opcode of failed request: 140 (RANDR)
   Minor opcode of failed request: 29 (RRSetPanning)
   Serial number of failed request: 49
   Current serial number in output stream: 49

@ashwinvis
Copy link
Owner

Can you share a screenshot of before and after @cjchristopher ?

@cjchristopher
Copy link
Author

I get different behaviour depending on the state before (resolutions and scaling), but in any case, no matter what state I have things in before, the after state is still not what I intend.
Which before state (and subsequent after) would you like me to provide screenshots of?

@ashwinvis
Copy link
Owner

Screenshots / photos of both the monitors before and after executing xrandr-extend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants