18 Commits (master)

Author SHA1 Message Date
Xaver Hugl 8d25550c22 backends/drm: support applying icc profiles with color management
While applications are still restricted to sRGB, this allows working on sRGB
content on displays with a wide color gamut as the whole profile gets applied,
instead of just the VCGT.

CCBUG: 439135
11 months ago
Xaver Hugl 7d02bc17d6 backends/drm: rework how atomic commits are tracked
Pending buffers for drm planes and crtcs are no longer tracked in the planes
and crtcs themselves, but instead in a DrmCommit object that is used as
the user data for the pageflip handler. This way multiple commits can be
pending at the same time without causing conflicts, and the handling of
pending buffers is simplified as well.
1 year ago
Xaver Hugl 87444f6ce3 backends/drm: offload atomic commits to a separate thread
This separate thread submits commits as late as possible, so that until
immediately before vblank the cursor position can still be updated, reducing
its latency and opening the door for more optimizations.
1 year ago
Aleix Pol Gonzalez 49a76ea772 Install KWaylandServer headers
There are use cases for the headers to be used, e.g. when implementing
wayland-specific workflows from an Effect.
In order to be able to use these, we also need to expose libkwin to be
imported as it carries the interfaces' symbols.

Signed-off-by: Victoria Fischer <victoria.fischer@mbition.io>
1 year ago
Vlad Zahorodnii 88ade3a409 Extract reusable egl swapchain bits
EGL rendering has some duplicated bits, so this change extracts
them to reduce code duplication.
1 year ago
Vlad Zahorodnii 3bd5e91226 Extract reusable qpainter swapchain bits
QPainter rendering has some duplicated bits, so this change extracts
them to reduce code duplication.
1 year ago
Vlad Zahorodnii 082301920e backends/drm: Port to GraphicsBuffer
This change ports the drm backend to the GraphicsBuffer and
GraphicsBufferAllocator.

The main motivation is to unify graphics buffer abstractions across
various backends and to prepare it for output layers, which could be
nicer if we could have direct control over the buffers.
1 year ago
Xaver Hugl f433213bd6 backends/drm: simplify how atomic commits are done
Instead of having every DrmProperty store pending values, store the data
for the next commit in a separate and temporary type. This simplifies the
code and makes it possible to do commits in a separate thread
2 years ago
Xaver Hugl d9077e36c5 backends/drm: use a common base class for property blobs
This simplifies the code a bit and makes more generic handling of blobs
possible
2 years ago
Xaver Hugl e4938297e6 scene: fix texture inversion with the drm backend
Specify the render target to buffer transformation and take that into
account in effects and when calculating the projection matrix.
2 years ago
Xaver Hugl 2417a0381f backends/drm: port from gbm_surface to a custom swapchain using gbm buffers 2 years ago
Vlad Zahorodnii d9f5d432be Port to KF6 2 years ago
Xaver Hugl a587e426f8 add autotest for the drm platform 2 years ago
Xaver Hugl c0c3ec09af Refactor DrmObject 4 years ago
Vlad Zahorodnii 93e0265e4e Move source code to src/ directory
Once in a while, we receive complaints from other fellow KDE developers
about the file organization of kwin. This change addresses some of those
complaints by moving all of source code in a separate directory, src/,
thus making the project structure more traditional. Things such as tests
are kept in their own toplevel directories.

This change may wreak havoc on merge requests that add new files to kwin,
but if a patch modifies an already existing file, git should be smart
enough to figure out that the file has been relocated.

We may potentially split the src/ directory further to make navigating
the source code easier, but hopefully this is good enough already.
4 years ago
Nicolas Fella 99947c8bd8 Use versionless Qt cmake target
This makes it easier to build against both Qt5 and Qt6

GIT_SILENT
4 years ago
Martin Flöser 1c61e61119 [autotests] Support new way to run the tests without need to install
Summary:
KWin was quite good in ensuring that you don't need to install by
passing paths to the tests. The new way is much nicer, so code is
adjusted for the new way. Also if we require a newer ECM in future we
need to support the new way.

No guarantee that the tests don't pick something up from the system env,
that needs more testing.

References: https://community.kde.org/Guidelines_and_HOWTOs/Making_apps_run_uninstalled

Test Plan: The tests which loaded helpers pass

Reviewers: #kwin, #plasma

Subscribers: plasma-devel, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D7543
7 years ago
Martin Flöser d4ba05a22f [autotests] Add tests for DRM platform plugin
Summary:
The addition of the test infrastructure is motivated by the regressions
caused by adding mode switching and transformation support.
A contributing factor to these regression is the fact that the DRM
platform does not have any tests. It is difficult to test this code as
it needs to work with hardware, thus we cannot use the real DRM library.
Instead we need to use mocking.

This change sets up some first basic tests with the help of a mockDrm
library. In order to better test the code as units the Drm classes are
slightly refactored. Most importantly the dependency to DrmBackend is
removed wherever possible and replaced by a simple int fd which is mostly
the only element used by the classes.

This first test introduces basic testing of a DrmObject. It is intended
to extend this to at least also test DrmPlane as a central piece of our
Drm platform plugin. This will also extend the tests of DrmObject.

Reviewers: #kwin, #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D8776
7 years ago