Hyprland icon indicating copy to clipboard operation
Hyprland copied to clipboard

Fix resize artifacts (stretching, bumps)

Open vaxerski opened this issue 1 year ago • 12 comments

WIP

Fixes resize artifacts notably when using the mouse to resize apps to larger sizes (stretching etc)

ref #7475

vaxerski avatar Aug 24 '24 14:08 vaxerski

ready for review

vaxerski avatar Aug 24 '24 15:08 vaxerski

Um, I don't see a difference.

diniamo avatar Aug 24 '24 17:08 diniamo

well I surely do, mind to get a recording?

vaxerski avatar Aug 24 '24 17:08 vaxerski

Definitely can see the improvement.

https://github.com/user-attachments/assets/8ec2f609-88be-47fc-9472-aa8ffe7a78dd

And with patch

https://github.com/user-attachments/assets/15fabbe8-bfa1-45cb-85af-376d97a020ba

Notice no bg flash on the left window.

MahouShoujoMivutilde avatar Aug 24 '24 23:08 MahouShoujoMivutilde

Oh, that's the only thing I wasn't looking at. A lot of the other problems are still there though.

diniamo avatar Aug 25 '24 08:08 diniamo

image this frame is odd, as the patch should expand the texture along the edges. What's that terminal and what settings?

vaxerski avatar Aug 25 '24 09:08 vaxerski

It's because its 1.25 monitor scale, can't reproduce on 1

Foot on defaults (with my bindings and colors), and hyprland now with hdefault-min.conf.txt

MahouShoujoMivutilde avatar Aug 25 '24 12:08 MahouShoujoMivutilde

This patch does this to my wallpaper at 1.25 scaling: image

Other than that and not fixing Electron resizing artifacts it does seem to fix stretching etc overall when resizing other things.

ferrreo avatar Aug 25 '24 13:08 ferrreo

looks very nice.

vaxerski avatar Aug 25 '24 14:08 vaxerski

can't repro, what wallpaper daemon?

vaxerski avatar Aug 25 '24 14:08 vaxerski

can't repro, what wallpaper daemon?

hyprpaper,

For more useful repro steps, it's a 4k wallpaper at 3440x1440 resolution @165hz for monitor config with 1.25 fractional scaling.

ferrreo avatar Aug 25 '24 14:08 ferrreo

Used it for a while, can't really tell the difference tbh. No noticeable problems have come up either.

Agent00Ming avatar Aug 25 '24 23:08 Agent00Ming

Can also see this effect https://github.com/hyprwm/Hyprland/pull/7499#issuecomment-2308849961 with nested sway and cage

With patch

27-09-2024-21_22_21

Without

27-09-2024-21_21_29

Latest git aqua / hl

MahouShoujoMivutilde avatar Sep 27 '24 18:09 MahouShoujoMivutilde

I should revisit this mr some day

vaxerski avatar Sep 27 '24 18:09 vaxerski

some day

😭

diniamo avatar Sep 27 '24 18:09 diniamo

some fixes including for those stretched things, but if I launch two terminals quickly they kinda wonkily stretch still

lmk if there are any other issues.

I am also doubting a bit whether this is the best solution. I mean, what should we fill the gaps with?

vaxerski avatar Sep 28 '24 18:09 vaxerski

any1?

vaxerski avatar Sep 29 '24 13:09 vaxerski

I think even with animations this is a clear improvement. Here is how it looks on my config. OLD:

https://github.com/user-attachments/assets/fe10ac87-8c0f-4d1c-bea9-97945601890c

NEW:

https://github.com/user-attachments/assets/6659bffc-aa2d-49ca-97be-80fb076bb656

Did not find any issues with it so far.

PointerDilemma avatar Sep 29 '24 14:09 PointerDilemma

Nested sway/cage issue is fixed.

This https://github.com/hyprwm/Hyprland/pull/7499#issuecomment-2308755431 still happens

Details

scale 1.25, slowed down

https://github.com/user-attachments/assets/a9c7f547-2a80-4d1e-b9dc-aadff7dcd20f

https://github.com/user-attachments/assets/55df78e2-f81c-43ce-ab7f-0b58f3a278bc

scale 1, normal speed

https://github.com/user-attachments/assets/22c33c08-d99e-455f-80e7-b0c3a0b3758d

https://github.com/user-attachments/assets/4ff0d16a-1561-4163-873c-fb24dd4ceb3d

MahouShoujoMivutilde avatar Sep 29 '24 15:09 MahouShoujoMivutilde

it's still better than main no? Lmk if there are any important bugs. The quick open bug is one that is annoying to me but I can live with it.

Basically, open two kitty terminals in quick succession, the first one will kinda squeeze, which looks odd.

@MahouShoujoMivutilde I am unsure why your one happens

vaxerski avatar Sep 29 '24 17:09 vaxerski

It's definitely better. I don't see any other bugs, nor do I see any problem with kitty.

Details

https://github.com/user-attachments/assets/df7fcff7-6277-4c23-a744-5a715fa8072a

MahouShoujoMivutilde avatar Sep 29 '24 18:09 MahouShoujoMivutilde

https://github.com/user-attachments/assets/f17e88cc-c585-4407-83aa-ed0919484be5

clearly visible here

vaxerski avatar Sep 29 '24 18:09 vaxerski

Oh, yeah, I see now. I just had my

    bezier = cst, 0.84, 0.37, 0.2, 0.62
    animation = windows, 1, 7, cst
    animation = windowsMove, 1, 2, default
    animation = windowsOut, 1, 3, default, popin 80%

so it wasn't visible to me.

With animation = windows, 1, 7, cst, if I open another terminal during about midpoint of the opening animation of the first, this I can reproduce the similar effect, but in the form of a vertical stretching, for both kitty and foot.

Details

https://github.com/user-attachments/assets/38b9b834-2322-4d17-b463-f81c39fb4a5b

MahouShoujoMivutilde avatar Sep 29 '24 18:09 MahouShoujoMivutilde

Hold on, does xwayland work for you?

Xorg is dead for me with this patch.

EDIT:

But works with default config... Okay, will try to narrow down.


So far can't reproduce even on my own config.

Idk what it was, I don't have VR headset, I didn't un/re-plug anything. But two times in a row, I launched hyprland with this patch, and xwayland was dead, no X apps would open, yet now, same config, and it works.

* This is this MR applied to 6649255d54f45a7e2fedd9b4be85fe5d11229c04

MahouShoujoMivutilde avatar Sep 29 '24 19:09 MahouShoujoMivutilde

magic

vaxerski avatar Sep 29 '24 20:09 vaxerski

Most likely, xwayland crashed for me for the same reason https://github.com/hyprwm/Hyprland/issues/7936 happens.

Idk what triggered it first two times, but it's unrelated to the patch.

MahouShoujoMivutilde avatar Sep 29 '24 23:09 MahouShoujoMivutilde

with @PaideiaDilemma's fix the resize bug is gone. Happy with merging this. Thanks everyone

vaxerski avatar Oct 04 '24 23:10 vaxerski