Commit graph

283 commits

Author SHA1 Message Date
Honkazel
a19cf76ee1
clang-tidy: fix some errors (#166)
* clang-tidy: fix some errors

* ...Eh?
2025-04-22 23:23:23 +02:00
Tom Englund
c8282f4982
atomic: fix compiler warning with string (#164)
the compiler tries to optimize this and inlines the +=, which might involve raw memcpy operations,
and in doing so, it thinks there is a chance that the internal buffer doesnt have enough space.
use ostringstream instead, and return the string from that.
2025-04-10 14:47:15 +02:00
UjinT34
1d2dbd72c2
drm: restore hdr metadata after vt switch (#163) 2025-03-29 17:25:29 +01:00
Lee Bousfield
484b732195
backend: Fix compiler warnings (#160) 2025-03-17 13:07:53 +01:00
Vaxry
1c8fa0bf04 version: bump to 0.8.0 2025-03-16 22:00:48 +00:00
Lee Bousfield
b058847592
backend, allocator: Fix mGPU backend + allocator swapchain combos (#159) 2025-03-16 22:52:24 +01:00
André Silva
bea48d0bbe nix: mesa -> libgbm
d209d800b7
2025-03-14 08:35:25 +02:00
Lee Bousfield
258cfeb3d0
misc: Fix Attachment shared pointer reinterpret (#154) 2025-03-10 18:41:37 +01:00
Lee Bousfield
81498562d0
wayland: Fix backend idleCallbacks destruction (#151) 2025-03-06 18:37:11 +01:00
Tom Englund
b236a43699
drm: only scan connected connectors (#155)
only scan connected connectors when deciding which gpu to become primary
mux switched laptops still have connectors for internal panel but not
connected.
2025-03-04 14:58:38 +01:00
Lee Bousfield
7b5db3d8a2
drm: Add strict typing to attachment manager (#152)
* misc: Add strict typing to attachment manager

* misc: Trim down CAttachmentManager comments

* misc: Return full pointer in attachment manager
2025-03-02 22:32:33 +01:00
Lee Bousfield
09b3fd5932
drm: Fix multi-GPU support for Nvidia (#147)
* allocator: Don't force linear for multigpu if unsupported

* drm: Use an intermediate CPU buffer for blit if necessary

* drm: Add comment and cleanup style a bit

* drm: Fix formatting from comment addition

* drm: Use std::vector and std::span for intermediateBuf

* drm: Fix style and add null check

* drm: Remove TODO about pixel buf format
2025-03-02 03:07:00 +01:00
Lee Bousfield
76508fe1ec
drm: Use RAII to manage EGL context (#150) 2025-02-28 02:32:20 +01:00
Ikalco
e62592f0f4
drm/atomic: fix atomic reset being skipped, check nullptr elsewhere instead (#149) 2025-02-27 15:21:05 +01:00
UjinT34
2ff06343aa
drm: get max bpc from drm format (#146) 2025-02-23 18:33:41 +01:00
Vaxry
f239e5aadd backend: log no allocator errors 2025-02-11 18:27:43 +00:00
Ikalco
a3dda0d10c
drm: prioritize gpus with the most internal panels (#144) 2025-02-09 13:22:25 +01:00
Mihai Fufezan
427077ca92
CI: remove deprecated magic-nix-cache-action 2025-02-08 23:12:41 +02:00
Ikalco
ecd2c813e0
drm: only allow multigpu blit to implcit, not all external formats (#143) 2025-02-03 20:40:52 +01:00
Honkazel
343178ba45
core: Compiler fixes and options (#141)
* reorder ctors

* sign-compare

* Add some compile options from Hyprland
2025-02-02 13:46:00 +01:00
UjinT34
257b205079
drm/output: add api to set drm content type property (#140) 2025-02-02 01:42:56 +01:00
Ikalco
95506e561d
egl/drm: consolidate EGL init/state (#138)
* move renderer to EGLRenderer

* consolidate EGL state and initialization

* move over eglSync

* unbreak abi
2025-02-01 16:17:49 +01:00
Mihai Fufezan
48a000cf35
flake.lock: update 2025-01-29 22:44:05 +02:00
Vaxry
6934e7dc53 version: bump to 0.7.2 2025-01-28 23:45:26 +00:00
Vaxry
a0553cd65e headless/wayland: emit present events after commit
fixes https://github.com/hyprwm/Hyprland/issues/8087
2025-01-28 23:34:19 +00:00
Mihai Fufezan
7fe006981f
flake.lock: update 2025-01-23 14:46:37 +02:00
Ikalco
f0519bfebd
headless: fix headless supported formats (#136) 2025-01-23 01:07:33 +01:00
Honkazel
4edeb99390
core: add clang-tidy (#135) 2025-01-22 22:39:30 +01:00
vaxerski
e7719f9b9f version: bump to 0.7.1 2025-01-12 18:21:56 +01:00
UjinT34
10fb69da79
drm: remove wrong property settings (#133) 2025-01-12 17:03:59 +00:00
Jan Beich
69048021ac
core: Unbreak build with libc++ (#131)
* backend: remove unused headers after 511600133c

* backend: add missing header for libc++ after 03677f8561

src/backend/Backend.cpp:275:42: error: no member named 'find_if' in namespace 'std::ranges'
  275 |     const auto primary    = std::ranges::find_if(implementations, [](SP<IBackendImplementation> value) { return value->type() == Aquamarine::AQ_BACKEND_DRM; });
      |                             ~~~~~~~~~~~~~^
2025-01-11 05:12:51 +01:00
vaxerski
fe8ff219fd version: bump to 0.7.0 2025-01-10 19:52:13 +01:00
maround95
03677f8561
core: GPU hotplug support (#130) 2025-01-10 18:39:08 +00:00
UjinT34
c2369bc3ab
drm: Avoid excessive atomic properties updates (#95)
* do not set cursor planeProps unless smth changed

* do not skip cursor state flag setting

* drm: scan only cards and not outputs, safeguard against null renderer (#106)

* drm: dont scan card outputs

no need to scan for card[0-9]* and probe card0-eDP etc if they are kms,
bootvga and rendernodes etc. skip the wildcard and remove a unused
size_t variable.

* drm: dont commit state if renderer is missing

setting certain env vars to force egl implentations makes the render
creation fail on the second gpu. instead of causing a coredump,
safeguard commitState and let the monitor turn blank instead.

* props: bump version to 0.5.0

* drm: Validate conn before dereference in CDRMAtomicRequest::commit() (#108)

During startup, CDRMAtomicImpl::reset() may emit a call to method
commit of a CDRMAtomicRequest instance with member "conn" uninitialized,
leading to a segfault. Validate the the pointer before dereference it as
a workaround.

Fixes: 55ac962 ("DRM: preliminary atomic support")
Closes: https://github.com/hyprwm/aquamarine/issues/107

Signed-off-by: Yao Zi <ziyao@disroot.org>

* buffer: remove useless forward def

* drm: clearer flow when rescanning connectors (#113)

* consolidates into checkOutput for clearer flow when rescanning connectors

* add error log

* drm: allow multigpu blit from explicit to implicit (#114)

* version: bump to 0.5.1

* flake.lock: update

* flake.nix: gcc13 -> gcc14 (#118)

* drm: udev scan only drm_minor, not connectors (#119)

* drm: log errno set by drmModeAtomicCommit (#120)

* drm: moved null check for renderer to shouldBlit() (#109) (#121)

* drm: only fail INVALID format when enabled (#122)

* flake.lock: update

* drm: only clear buffers when fullReconfigure succeeds (#124)

* core/drm: Add HDR Support (#112)

* version: bump to 0.6.0

* drm: limit udev drm_minor to Linux after a132fa41be (#129)

Not implemented by libudev-devd yet:

[ERR] [AQ] drm: No gpus in scanGPUs.
[ERR] [AQ] drm: Found no gpus to use, cannot continue
[ERR] [AQ] DRM Backend failed

* do not set cursor planeProps unless smth changed

* test separate cursor commits

* do not change hdr blob unless asked to

* rebase

* split atomic commit processing and move hdr & colorspace into modeset

* fix wide color gamut flag & cleanup

* remove unused debug var

---------

Signed-off-by: Yao Zi <ziyao@disroot.org>
Co-authored-by: Tom Englund <tomenglund26@gmail.com>
Co-authored-by: Vaxry <vaxry@vaxry.net>
Co-authored-by: Ziyao <ziyao@disroot.org>
Co-authored-by: Ikalco <73481042+ikalco@users.noreply.github.com>
Co-authored-by: Mihai Fufezan <mihai@fufexan.net>
Co-authored-by: Austin Horstman <khaneliman12@gmail.com>
Co-authored-by: Richard Henninger <56615615+richen604@users.noreply.github.com>
Co-authored-by: Jan Beich <jbeich@FreeBSD.org>
2025-01-10 18:38:51 +00:00
Jan Beich
5bc315ed56
drm: limit udev drm_minor to Linux after a132fa41be (#129)
Not implemented by libudev-devd yet:

[ERR] [AQ] drm: No gpus in scanGPUs.
[ERR] [AQ] drm: Found no gpus to use, cannot continue
[ERR] [AQ] DRM Backend failed
2025-01-07 11:35:34 +00:00
vaxerski
4846091641 version: bump to 0.6.0 2025-01-05 19:40:53 +01:00
UjinT34
aeab812e0f
core/drm: Add HDR Support (#112) 2025-01-05 14:44:39 +00:00
Ikalco
f7082bef81
drm: only clear buffers when fullReconfigure succeeds (#124) 2025-01-01 20:36:46 +00:00
Mihai Fufezan
eecb74dc79
flake.lock: update 2024-12-23 00:27:26 +02:00
Ikalco
5e3f6013e9
drm: only fail INVALID format when enabled (#122) 2024-12-21 23:14:38 +01:00
Richard Henninger
a23e9a9bdf
drm: moved null check for renderer to shouldBlit() (#109) (#121) 2024-12-18 16:01:56 +01:00
Ikalco
ae2bf9192d
drm: log errno set by drmModeAtomicCommit (#120) 2024-12-18 15:55:53 +01:00
Ikalco
a132fa41be
drm: udev scan only drm_minor, not connectors (#119) 2024-12-17 02:58:49 +01:00
Austin Horstman
3375378354
flake.nix: gcc13 -> gcc14 (#118) 2024-12-16 22:22:52 +01:00
Mihai Fufezan
8e77618b40
flake.lock: update 2024-12-16 17:59:57 +02:00
Vaxry
9441860f40 version: bump to 0.5.1 2024-12-13 22:42:36 +00:00
Ikalco
9fc2d8e1fb
drm: allow multigpu blit from explicit to implicit (#114) 2024-12-09 22:14:39 +01:00
Ikalco
1af9816244
drm: clearer flow when rescanning connectors (#113)
* consolidates into checkOutput for clearer flow when rescanning connectors

* add error log
2024-12-07 17:53:24 +01:00
Vaxry
7dea26bba0 buffer: remove useless forward def 2024-12-06 15:15:24 +00:00
Ziyao
4468981c1c
drm: Validate conn before dereference in CDRMAtomicRequest::commit() (#108)
During startup, CDRMAtomicImpl::reset() may emit a call to method
commit of a CDRMAtomicRequest instance with member "conn" uninitialized,
leading to a segfault. Validate the the pointer before dereference it as
a workaround.

Fixes: 55ac962 ("DRM: preliminary atomic support")
Closes: https://github.com/hyprwm/aquamarine/issues/107

Signed-off-by: Yao Zi <ziyao@disroot.org>
2024-11-18 19:43:51 +00:00