hyprwm / Hyprland

Hyprland is an independent, highly customizable, dynamic tiling Wayland compositor that doesn't sacrifice on its looks.
https://hyprland.org
BSD 3-Clause "New" or "Revised" License
21.33k stars 899 forks source link

Upside down monitor rotation issue #8222

Open mikiadev opened 1 week ago

mikiadev commented 1 week ago

Already reported ? *

Regression?

No

System Info and Version

System/Version info ```sh Hyprland, built from branch at commit 4520b30d498daca8079365bdb909a8dea38e8d55 (version: bump to 0.44.1). Date: Wed Oct 9 12:54:39 2024 Tag: v0.44.1, commits: 5309 built against aquamarine 0.4.2 flags: (if any) System Information: System name: Linux Node name: yoga Release: 6.11.4-0-clear Version: #1 SMP Tue, 22 Oct 2024 14:08:07 +0000 GPU information: 00:02.0 VGA compatible controller [0300]: Intel Corporation Raptor Lake-P [Iris Xe Graphics] [8086:a7a1] (rev 04) (prog-if 00 [VGA controller]) os-release: NAME="Arch Linux" PRETTY_NAME="Arch Linux" ID=arch BUILD_ID=rolling ANSI_COLOR="38;2;23;147;209" HOME_URL="https://archlinux.org/" DOCUMENTATION_URL="https://wiki.archlinux.org/" SUPPORT_URL="https://bbs.archlinux.org/" BUG_REPORT_URL="https://gitlab.archlinux.org/groups/archlinux/-/issues" PRIVACY_POLICY_URL="https://terms.archlinux.org/docs/privacy-policy/" LOGO=archlinux-logo plugins: unknown: not runtime Config File: /home/mika/.config/hypr/monitors.conf: Read Succeeded # Generated by nwg-displays on 2024-10-24 at 12:15:08. Do not edit manually. monitor=eDP-1,2880x1800@60.0,0x0,1.2 monitor=eDP-2,2880x1800@60.0,0x1500,1.2 monitor=DP-1,2560x1440@59.95,2400x840,1.0 # hyprctl monitors Monitor eDP-1 (ID 0): 2880x1800@60.00100 at 0x0 description: Samsung Display Corp. 0x4167 make: Samsung Display Corp. model: 0x4167 serial: active workspace: 1 (1) special workspace: 0 () reserved: 0 0 0 39 scale: 1.20 transform: 0 focused: no dpmsStatus: 1 vrr: false solitary: 0 activelyTearing: false disabled: false currentFormat: XRGB8888 availableModes: 2880x1800@60.00Hz Monitor eDP-2 (ID 1): 2880x1800@60.00100 at 0x1500 description: Samsung Display Corp. 0x4182 make: Samsung Display Corp. model: 0x4182 serial: active workspace: 2 (2) special workspace: 0 () reserved: 0 0 0 39 scale: 1.20 transform: 0 focused: yes dpmsStatus: 1 vrr: false solitary: 0 activelyTearing: false disabled: false currentFormat: XRGB8888 availableModes: 2880x1800@60.00Hz Monitor DP-1 (ID 2): 2560x1440@59.95100 at 2400x840 description: Samsung Electric Company S24H85x H4ZJB00076 make: Samsung Electric Company model: S24H85x serial: H4ZJB00076 active workspace: 3 (3) special workspace: 0 () reserved: 0 0 0 39 scale: 1.00 transform: 0 focused: no dpmsStatus: 1 vrr: false solitary: 0 activelyTearing: false disabled: false currentFormat: XRGB8888 availableModes: 2560x1440@59.95Hz 1920x1080@60.00Hz 1920x1080@60.00Hz 1920x1080@59.94Hz 1920x1080@50.00Hz 1920x1080@50.00Hz 1680x1050@59.88Hz 1600x900@60.00Hz 1280x1024@75.03Hz 1280x1024@60.02Hz 1440x900@59.90Hz 1280x800@59.91Hz 1152x864@75.00Hz 1280x720@60.00Hz 1280x720@60.00Hz 1280x720@60.00Hz 1280x720@59.94Hz 1280x720@50.00Hz 1280x720@50.00Hz 1024x768@75.03Hz 1024x768@70.07Hz 1024x768@60.00Hz 832x624@74.55Hz 800x600@75.00Hz 800x600@72.19Hz 800x600@60.32Hz 800x600@56.25Hz 720x480@60.00Hz 720x480@59.94Hz 640x480@75.00Hz 640x480@72.81Hz 640x480@66.67Hz 640x480@60.00Hz 640x480@59.94Hz 720x400@70.08Hz ```

Description

I have a Lenovo Yoga Book 9i double screen laptop with identical touch screens, however the top monitor (eDP-1) is physically installed upside down. With kernel parameter video=eDP-1:2880x1800,rotate=180 the screen can be rotated and it shows up in hyprland in correct orientation. I'm not that familiar with Wayland or Hyprland so far to tell where this problem is but I'm starting here.

Despite the top monitor showing up in correct orientation mouse is completely inverted (and cursor upside down), moving mouse above from the left corner of the bottom monitor the cursor comes out of top monitor's top right corner with mouse travel inverted on both axis. Is this is a bug or does anybody have ideas how to fix this? Libinput? (without using the kernel video parameter, then normal monitors.conf rotation works but then out of Hyprland everything is upside down...)

How to reproduce

Connect external monitor upside down and use kernel video= to flip it.

Crash reports, logs, images, videos

20241024_122031

vaxerski commented 1 week ago

why not just use transforms in hyprland instead of kernel parameters?

l3all commented 1 week ago

Fixing the issue in https://github.com/hyprwm/Hyprland/issues/3947 would fix this issue

l3all commented 1 week ago

I found a fix here https://github.com/hyprwm/Hyprland/issues/1588 Installed https://github.com/JeanSchoeller/iio-hyprland to fix my issue

mikiadev commented 1 week ago

I found a fix here #1588 Installed https://github.com/JeanSchoeller/iio-hyprland to fix my issue

Using iio-hyprland makes no difference, I mean the mouse movement is still inverted.

vaxerski commented 1 week ago

stop using a kernel parameter and use hyprland's transforms?

mikiadev commented 6 days ago

stop using a kernel parameter and use hyprland's transforms?

Firstly that prevents auto-rotation from working, it just flips it upside down, both in landscape and portrait as it's originally upside down. Kernel instructs intended orientation and Hyprland is not following it, as a workaround I am currently using a script that toggles monitors. But that also requires workaround to greeter and console is still upside down. And using kernel parameter fixes it for xorg, so console and greeter are right way to begin with.