Commit graph

21 commits

Author SHA1 Message Date
UjinT34
38a7f03cf0
renderer: refactor part 7: api fixes (#13631)
Part 7 of ujin's refactors

---------

Co-authored-by: Vaxry <vaxry@vaxry.net>
2026-03-28 21:41:45 +00:00
ItsOhen
8aff500351
internal: fix relative path header locations (#13650)
Or plugins can't build.
2026-03-13 08:53:07 -05:00
UjinT34
966f20d305
renderer: refactor resources and flags (#13471) 2026-03-07 13:13:34 +00:00
UjinT34
4152ac76d0
renderer: refactor Texture, Framebuffer and Renderbuffer (#13437)
Part 1 of the renderer refactors
2026-03-06 21:44:10 +00:00
UjinT34
a5858018d8
renderer: shader variants refactor (#13434)
Part 0 of renderer reworks.
2026-03-06 21:05:10 +00:00
Tom Englund
fab3370254
renderer: minor framebuffer and renderbuffer changes (#12831)
* framebuffer: dont release if format or size changes

we dont have to release and recreate both the texture and framebuffer if
size or format changes, we can just bind the texture and call glTexImage2D
with the new format and size.

* framebuffer: set the alloced viewport size

if monitor size mismatch with the allocated m_size its going to set a
mismatched viewport and cause rendering issues. and if they are
mismatching there is a missing alloc call.

* renderbuffer: cleanup unneded binds

the renderbuffer is attached to the fbo and trying to rebind it in
bind() is causing unnecessery state changes, just bind the fbo.

add safeguard in the destructor, the constructor can return early on
failure and leave m_rbo empty or m_image as EGL_NO_IMAGE_KHR.
2026-01-03 15:13:01 +01:00
Vaxry
6175ecd4c4
debug: move to hyprutils' logger (#12673) 2025-12-18 17:23:24 +00:00
Kamikadze
beee22a95e
refactor: Use new hyprutils casts (#11377) 2025-08-14 15:44:56 +01:00
78e9eddfb6
core: use new typed signals from hu (#10853) 2025-07-08 18:56:40 +02:00
davc0n
997fefbc11
render: refactor class member vars (#10292)
* render: refactor class member vars

* render: fix clang format
2025-05-05 23:44:49 +02:00
davc0n
241a4935a2
compositor: refactor class member vars (#10141) 2025-04-22 15:23:29 +02:00
Tom Englund
f7fcbe32c9
renderer: various fixes towards improving gpu calls robustness (#9188)
ensure framebuffer textures are detached and deleted, avoid leaving framebuffers bound when not needed

* render: avoid calling glDeleteProgram on no program

its safe to do so but it adds a bunch of unnecessery lines in apitrace
when tracing. if guard it and return early.

* opengl: ensure texture and buffers are unbound

ensure bound buffers are unbound after use, also detach textures from
framebuffer before deleting it otherwise it will become dangling and
essentially leak.
2025-02-08 01:46:26 +01:00
user111111111111111111111111111111111
2bad73354a
core: cleanup header includes (#9088)
Cleanup some unneeded includes to speed up compilation
2025-01-17 15:21:35 +00:00
Tom Englund
1840a907a8
renderbuffer: ensure framebuffer gets deleted (#7363)
after commit 4b4971c it uses m_iFbAllocated and deletes if upon calling
release() but Renderbuffer generates directly on m_iFb without calling
alloc() meaning it wont be deleted on release(), set m_iFbAllocated to
true after generating the buffer.
2024-08-16 10:09:01 +01:00
Vaxry
016da234d0
Core: Move to aquamarine (#6608)
Moves Hyprland from wlroots to aquamarine for the backend.

---------

Signed-off-by: Vaxry <vaxry@vaxry.net>
Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
Co-authored-by: Jan Beich <jbeich@FreeBSD.org>
Co-authored-by: vaxerski <vaxerski@users.noreply.github.com>
Co-authored-by: UjinT34 <41110182+UjinT34@users.noreply.github.com>
Co-authored-by: Tom Englund <tomenglund26@gmail.com>
Co-authored-by: Ikalco <73481042+ikalco@users.noreply.github.com>
Co-authored-by: diniamo <diniamo53@gmail.com>
2024-07-21 13:09:54 +02:00
13bc7e1e14 style: fix clang-format 2024-07-13 12:36:35 +02:00
Tom Englund
ac11771348
core: fix a few ubsan issues reported at exit of hyprland (#6699)
* watchdog: dont detach and cause race condition

instead of detaching and causing a race condition on destruction where
the thread is alive and watchdog has been destroyed, check if its
joinable and join it on destruction.

causes heap use after free on exit of compositor.

* render: add checks for compositor shutting down

avoid member call on null pointer, if the g_pHyprRenderer is destroyed
we can call the member makeEGLCurrent on it, causes undefined behaviour
on destruction of the compositor/hyprrenderer.

found with ubsan.
2024-06-28 22:24:32 +02:00
Vaxry
6967a31450
wayland/core: move to new impl (#6268)
* wayland/core/dmabuf: move to new impl

it's the final countdown
2024-06-08 10:07:59 +02:00
ed411f53bd cursor: move to a hyprland impl
This moves wlr_cursor to a completely new impl mostly under
CPointerManager

Also adds beginSimple to OpenGL for simple render passes (e.g. cursor)
2024-05-09 13:37:39 +01:00
03c6f4506a internal: various improvements to avoid crashes on exit 2023-12-06 14:46:29 +00:00
Vaxry
2ebfd0c745
renderer: Move to a full Hyprland GL rendering pipeline (#3920)
Also updates wlroots
2023-11-24 10:54:21 +00:00