Commit Graph

6235 Commits

Author SHA1 Message Date
Tom Englund
9adacef70b buffer: check if buffer fd already readable (#10894)
check if buffer fd is already readable, to avoid a lot of unnecessery
systemcalls and churn.
2025-07-01 11:32:17 +02:00
Tom Englund
f464dfbefa shader: replace texture2d with texture (#10893)
* shader: replace texture2d with texture

remove unused v_color and replace deprecated texture2d with texture.

* shader: use the more modern essl3 extension

GL_OES_EGL_image_external_essl3 provides support for samplerExternalOES
in texture function, aquamarine already use it. apply it here too.
2025-07-01 11:32:00 +02:00
Tom Englund
8c37d2ce25 sessionlock: restore cursor if hidden on unlock (#10889)
if session locks have hidden the cursor its gonna be missing unless a
new cursor shape is set, hovering windows makes us get one, moving the
wallpaper/desktop does not. set it again to left_ptr as is default on
compositor start.
2025-07-01 11:31:10 +02:00
Karun Sandhu
ee8978b961 flake.lock: update 2025-06-29 19:29:36 +03:00
Vaxry
ab900d8752 screencopy: fix improper box calculations for transforms (#10870) 2025-06-28 17:01:14 +02:00
Vaxry
0fea173fc8 unbind: add unbind all 2025-06-28 14:55:13 +02:00
Mihai Fufezan
a01d20cfe8 CI/Nix: fix rebase oopsie 2025-06-27 16:56:52 +03:00
Vaxry
e4b6fedfb9 tester: simplify adding test files 2025-06-27 12:18:45 +02:00
Vaxry
1fc7e80bdb README: update previews 2025-06-27 12:06:21 +02:00
Mike Will
b850b35778 snap: move gapOffset logic outside of for loop (#10861) 2025-06-27 12:01:45 +02:00
Mihai Fufezan
2796ec1cf2 CI/Nix: separate xdph from hl 2025-06-26 23:38:23 +03:00
Vaxry
3d6476c902 Core: Add a test suite (#9297)
Adds a test suite for testing hyprland's features with a runtime tester

---------

Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
2025-06-26 19:43:39 +02:00
rafiq
9a67e0421b renderer: clamp rounding_power (#10816) 2025-06-26 19:26:46 +02:00
outfoxxed
3bbdf9dc5a protocols: add ext-workspace implementation (#10818) 2025-06-26 18:32:44 +02:00
sam
1f337a7a5e hyprctl: replace read-only strings with std::string_view (#10851) 2025-06-26 12:28:35 +02:00
UjinT34
452a158107 config: use parseScale for monitorv2 (#10852) 2025-06-26 12:28:21 +02:00
Tom Englund
f4f090e4b2 renderer: reduce a lot of glcalls and cache various states (#10757)
* opengl: cache viewport state

according to nvidia docs calling glViewPort unnecessarily on the same
already set viewport is wasteful and can cause state changes when not
needed. cache it in a struct and only call it when the viewport is
actually changing.

* opengl: cache glenable/gldisable state

avoid making multiple glenable/gldisable calls on already set caps, can
cause state changes and incur driver overhead.

* opengl: cache glscissor box

only call glscissor if the box actually has changed, try to avoid state
changes.

* opengl: cache gluniform calls

cache the gluniform calls, the uniform values are cached in driver per
program only the drawcalls setting the uniform yet again with the same
value on same location is causing more overhead then caching it ourself
and just no oping on it if no changes.

* shader: rewrite handling of uniforms and state

this is way faster as we don't need to mess with maps (hashing, etc) and instead can just use an array

* opengl: stuff and 300 shaders

* opengl: typo

* opengl: get the uniform locations properly

now that the legacy shaders are gone get the uniformlocations for
SKIP_CM etc, so they can be properly set and used depending on if
cm_enabled is set to false or true, before it was falling back to a
legacy shader that didnt even have those uniforms.

* opengl: check epsilon on float and remove extra glcall

seems an extra unset glcall was added, remove it. and check the float
epsilon on the glfloat.

* opengl: remove instanced shader draw

remove the instanced boolean from the vertex shader, might be neglible
differences, needs more benchmark/work to see if its even worth it.

* texture: cache texture paramaters

parameters where occasionally set twice or more on same texture, short
version wrap it and cache it. and move gpu churn to cpu churn.

add a bind/unbind to texture aswell.

* texture: use fast std::array caching

cache the texparameter values in fast array lookups
and incase we dont want it cached, apply it anyways.

* shader: fix typo and hdr typo

actually use Matrix4x2fv in the 4x2fv cache function, and send the
proper float array for hdr.

* texture: make caching not linear lookup

make caching of texture params not linear.

* minor style changes

* opengl: revert drawarrays

revert the mostly code style reduce loc change of drawarrays, and focus
on the caching. its a if else case going wrong here breaking
blur/contrast amongst others drawing.

---------

Co-authored-by: Vaxry <vaxry@vaxry.net>
2025-06-25 12:42:32 +02:00
Mihai Fufezan
5a348fb7df Nix: filter src using fileset
Allows reusing already-built derivation when changing files outside the
ones defined in the fileset.
2025-06-24 21:39:42 +03:00
Vaxry
aea8132001 buffer: don't use crazy listener::emit() 2025-06-24 15:23:53 +02:00
UjinT34
cf7e3aa448 renderer/cm: Add automatic hdr (#9785) 2025-06-23 14:33:09 +02:00
Vaxry
c7c8ca475b config: add missing description for enforce_permissions 2025-06-23 13:56:02 +02:00
Vaxry
24e5f9974d hyprctl: print no open windows instead of invalid request on empty clients 2025-06-23 13:49:30 +02:00
Vaxry
dd33128c2f input: fix mouseDown triggering hl ops on locked (#10809) 2025-06-22 12:49:13 +02:00
zacoons
8b1d5560cf renderer: add wrapping options to renderTextureWithBlur method (#10807) 2025-06-21 19:03:28 +02:00
vaxerski
2388874738 [gha] Nix: update inputs 2025-06-21 14:22:28 +00:00
Vladimir-csp
4be32dbff4 xwayland: Don't leave shell process (#10802) 2025-06-21 16:21:08 +02:00
fufexan
8ebff1948f [gha] build man pages 2025-06-19 22:49:42 +00:00
Mihai Fufezan
a301d54df8 treewide: hyprland.org -> hypr.land 2025-06-20 01:49:20 +03:00
Mihai Fufezan
ff2f85641a CI/Nix: add cache-nix-action
Use nixbuild/nix-quick-install-action which pairs well with
nix-community/cache-nix-action.

Should help with build times by reducing the number of packages needing
to be re-downloaded on each run.

Parameters are taken from https://github.com/nix-community/cache-nix-action
and may be tweaked later.
2025-06-20 01:37:59 +03:00
Jasson
b49d0ca20e xwayland: Fix crash when copying from wayland to xwayland (#10786) 2025-06-19 19:44:38 +02:00
Vaxry
86b5e3bfbc config: nuke explicit_sync settings
were not used anymore, explicit is on by default
2025-06-19 14:58:03 +02:00
Vaxry
54ccf9c6b3 renderer: make lock fail textures dynamically loaded
this should reduce idle vram usage by a whopping 16MB, but also might fix the tty unknown issue.
2025-06-19 13:46:42 +02:00
Vaxry
e999ad664d hookSystem: avoid using manual mem management, fix leak
fixes #10790
2025-06-19 11:58:12 +02:00
7mile
9fb6b5d96b input: Fix incorrect localcoords with a surface above an XWayland window (#10773) 2025-06-18 22:48:51 +02:00
Vaxry
0fb63c68e9 permissions: properly print config requests for plugins 2025-06-18 22:43:04 +02:00
Vaxry
83a4c61048 plugins: don't update config plugins on state unchanged
fixes #10781
2025-06-18 22:42:57 +02:00
Jasson
bef1321f00 xwayland: fix minor errors in previous refactor (#10763) 2025-06-18 10:16:22 +02:00
Jacob Ilias Komissar
0ece4af36a grpupbar: Add config options to color inactive and locked groupbar titles (#10667) 2025-06-16 22:40:38 +02:00
Vaxry
aba2cfe7a8 asyncDialogBox: lock box in fdWrite to prevent a uaf (#10759) 2025-06-16 17:02:08 +02:00
Vaxry
d4e8a44087 windowrules/move: clamp max pos in onscreen to avoid assert crash
fixes #10760
2025-06-16 13:43:06 +02:00
Jasson
1905c41c65 xwayland: Use RAII instead or freeing memory manually (#10677)
As suggested by clang-tidy
2025-06-16 13:31:46 +02:00
UjinT34
bd5703d5c6 protocols/cm: fix wp invalid luminance check (#10752) 2025-06-15 23:13:57 +02:00
Vaxry
d037c54260 protocols: support xdg-shell v7
there's nothing special we need to add for this rev
2025-06-15 12:21:16 +02:00
UjinT34
c3894d9288 config/monitor: Add monitor v2 HDR rules (#10623) 2025-06-15 12:15:18 +02:00
Vaxry
3db3baa19e opengl: use a stack for storing monitor transform enabled
fixes #10487
2025-06-15 12:11:28 +02:00
Vaxry
57d20a1bf6 internal: clean up dead snapshot code 2025-06-15 11:51:27 +02:00
Vaxry
472b52bc06 cursor: reset hc data after theme change
theme change invalidates the cairo surfaces there

fixes #10636
2025-06-15 11:47:10 +02:00
vaxerski
79b9edb85b [gha] Nix: update inputs 2025-06-15 09:46:31 +00:00
may
f08167c877 input: add sticky option for drag_lock (#10702)
* allow configuring the sticky option for `drag_lock`

* enable sticky drag_lock by default as recommended by libinput

recommended here:
https://lists.freedesktop.org/archives/wayland-devel/2024-November/043860.html
2025-06-15 11:45:06 +02:00
Joel-Valenciano
ad85406220 drm-lease: Add Multi-GPU Support (#10099) 2025-06-13 15:17:32 +02:00