hanatos / vkdt

raw photography workflow that sucks less
https://jo.dreggn.org/vkdt
BSD 2-Clause "Simplified" License
389 stars 36 forks source link

Window Resize Lag #145

Open jedypod opened 3 weeks ago

jedypod commented 3 weeks ago

When resizing a vkdt window on Rocky Linux 9.4 under X11, it takes quite a while for the window contents to redraw.

https://github.com/user-attachments/assets/0c659442-86ef-401c-8029-516ecf31a0bd

hanatos commented 2 weeks ago

hmm i'm using a tiled window manager so i don't usually resize my windows much. what happens is that it re-rasterises the fonts for the new pixel size. vkdt resizes all content wrt vertical window size, regardless of system dpi and scale settings and hidpi nonsense. the lag in your video seems to be particularly bad though. this does update a fair bit faster on my machine if i drag the corner.

macos seems to resize the old backbuffer in such cases to make it look smoother. i wonder if modern wayland compositors would do similar things.

anyways, the solution for font rendering is of course something more elaborate like SDF fonts or whatever slug is doing or https://github.com/GreenLightning/gpu-font-rendering .

temporary workarounds could be keeping the old textures and only re-rasterising in the background once the size remains stable for a while.. but this sounds like an awful lot of code complexity for a hack to me.

hanatos commented 4 days ago

okay. this is shocking slow in your video. window manager issue? here's mine:

https://github.com/user-attachments/assets/b39d2295-98d1-4073-a53b-3640019bee4b

blitzgneisserin commented 3 days ago

okay. this is shocking slow in your video. window manager issue? here's mine: recording.mp4

This looks like Arch and Wayland. Did you switch? This looks like waybar but which compositor is it?

Edit: rounded cornners. Hyprland?

hanatos commented 3 days ago

hah, well observed with keen eye :) but this is still debian/sid, i only compiled hyprland from git and used some random waybar config from the internets (hence arch logo). some issues aside i think wayland is great. failed to get any other compositor running, but i like the fast moving spirit of this one.

blitzgneisserin commented 3 days ago

wayland is great

Yea, told you, it's nice. Especially Hyprland.