Native resolution for games

I’ve seen this asked elsewhere with not very satisfactory answers. But since we have the forums, let it be here.

So my monitor config looks like this:

monitor=eDP-2,[email protected],0x0,1.6

Notice the 1.6 scale. When opening a game, inside the game only a fractional resolution is available as the max resolution, not the 2560x1600 that my monitor supports.

Is there a way to sort of reset the scale to 1 only for game windows?

I was looking for ways to do this with a windowrule. But I don’t think it’s possible at the moment.

The work around for now is to not run games on native Wayland and to not scale all X windows by adding this to the config:

xwayland {
    force_zero_scaling = true
}

Correct, I’ll add more.

If you don’t want to use that for whatever reason, or you want a game run at a custom resolution, you can use csgo-vulkan-fix: hyprland-plugins/csgo-vulkan-fix at main · hyprwm/hyprland-plugins · GitHub

The name is not that obvious, but it’s essentially a plugin that allows you to add “profiles” where matching windows get forced into a custom resolution without them realizing it, meaning you can set any and all resolutions and the game will work with it.

Especially useful for gaming on stretched aspect ratios, lower resolutions without the cursor breaking, etc.

This is cool, thanks. I’ll take a look :slight_smile:

When configuring the plugin:

plugin {
    csgo-vulkan-fix {
        # Whether to fix the mouse position. A select few apps might be wonky with this.
        fix_mouse = true

        # Add apps with vkfix-app = initialClass, width, height
        vkfix-app = cs2, 1650, 1050
        vkfix-app = myapp, 1920, 1080
    }
}

Does initialClass have to be a full mach? Or, can I use regex?

Full match required here, no regex

1 Like

Are there other available options for this plugin? Read the GitHub, but that’s all there’s in there.

I tested this with Marvel Rivals. This caused the resolution to be correct (though in-game you couldn’t set it, the fractional res still reported, but it was obvious that was not it), but the mouse (and controller) don’t work correctly.

Specifically, when using this plugin, the pointer can move freely, but clicking only works inside a small rectangle located at the top left of the window. Same with controller, except with the controller is a bit worse because then the pointer wouldn’t even leave said rectangle.

For that game specifically, I’m now using the Wayland driver: PROTON_ENABLE_WAYLAND=1 instead. No issues so far, so I think that’s what I’ll do for now.

there’s the fix mouse config opt that can be flipped to see if it helps

There is an issue with Render96ex starting from Hyprland 0.51:

So if you exceed over 680x480 youll have to PRAY for the rng to hit the right thing so the gl context survives. If you want fullscreen, your only chances are to use OMM or pray or use another fork like sm64ex (weird right)

Welp, good to know.

Been using these x apps without scaling and that’s been fine so far.