Simon Ser
83670fce65
examples: remove dependency on GLES2 for compositor examples
...
Most of the examples had a GLES2 dependency, but weren't using it.
Convert multi-pointer to wlr_renderer instead of using directly
glClear.
4 years ago
Simon Ser
fd7e565ce3
examples: use wlr_output_preferred_mode
4 years ago
Kenny Levinsen
3432ab2ba7
backend/session: Close remaining devices on destroy
4 years ago
Kenny Levinsen
e7515529ce
backend/session: Close fd in wlr_session_close_file
...
This was lost in the session_impl removal refactor.
4 years ago
ayaka
ed1924800d
render: make GLES2 renderer optional
...
Allow selecting whether the GLES2 renderer gets enabled.
Co-authored-by: Simon Ser <contact@emersion.fr>
4 years ago
Simon Zeni
122d6c6988
renderer: create pixman renderer if getting drm fd failed
4 years ago
Simon Zeni
0d90dddfab
render: introduce pixman renderer
4 years ago
Simon Ser
9de93a866f
backend/wayland: fallback to wl_shm on missing render node
4 years ago
Simon Ser
80865351bd
backend/wayland: add support for wl_shm buffers
4 years ago
Simon Ser
c6b009ef85
render: introduce shared memory allocator
...
It allocates in local main memory via shm_open, and provides a FD
to allow sharing with other processes.
This is suitable for software rendering under the Wayland and X11
backends.
4 years ago
Simon Ser
6c61de996c
buffer: introduce wlr_buffer_get_shm
...
References: https://github.com/swaywm/wlroots/issues/2399#issuecomment-769408708
4 years ago
Simon Zeni
0b9288ec0b
buffer: introduce wlr_buffer_get_data_ptr
...
The function has been place in an internal header for API stability
reasons.
4 years ago
Simon Ser
9f33d8ad39
readme: mark libseat as mandatory dep
...
[1] has made wlroots unconditionally depend on libseat. Mention this
in the README.
[1]: https://github.com/swaywm/wlroots/pull/2839
4 years ago
Ryan Farley
d87ede0d69
xwayland/sockets: ensure proper permissions
...
Create a private UNIX socket directory (755), or use an existing one but
ensure proper permissions are set to prevent meddling from other users.
4 years ago
Simon Ser
3c6826df71
examples/rotation: error out on invalid option
4 years ago
Simon Zeni
84dea55b20
render: rename get_dmabuf_render_formats into get_render_formats
4 years ago
Simon Ser
004cf887b7
render/gles2: prevent imported DMA-BUF textures from being mutated
...
The compositor shouldn't write to client buffers if the client
attaches a DMA-BUF to a wl_surface, then attaches a shm buffer.
Make gles2_texture_write_pixels return an error to prevent this
from happening.
4 years ago
Simon Ser
1e5460d4c6
backend/x11: check for connection errors
4 years ago
Simon Ser
053ebe7c27
backend/drm: terminate display on drmHandleEvent failure
4 years ago
Simon Ser
846e0838d6
backend/libinput: terminate display on error
4 years ago
Kenny Levinsen
7f09085461
backend/session: Remove session_impl
...
libseat provides all session functionality, so there is no longer need
for a session backend abstraction. The libseat device ID, seat handle
and event loop handle are moved to the main wlr_session and wlr_device
structs.
4 years ago
Kenny Levinsen
3f87c2caea
backend/session: Remove noop backend
...
This is instead delegated to libseat.
4 years ago
Kenny Levinsen
d037c2dddc
backend/session: Remove direct backend
...
This is instead delegated to libseat.
4 years ago
Kenny Levinsen
95b657ba80
backend/session: Make libseat mandatory
4 years ago
Kenny Levinsen
21e8a940b8
ci: Add libseat-dev to alpine
4 years ago
Yuya Nishihara
3c5cc02b18
xcursor: use memcpy() to append string of known size
...
Since len <= strlen(elt) is known, we don't need a str*() function. Let's
simply do memcpy() to suppress linter false positive.
Fixes #2777 .
4 years ago
Yuya Nishihara
a71d565138
Revert "xcursor: use strncat instead of strncpy"
...
This reverts commit 7dffe9339b
, which introduced
another linter error with -O3:
error: ‘strncat’ specified bound 7 equals source length [-Werror=stringop-overflow=]
This makes sense because strncat(dest, "cursors", strlen("cursors")) is moot
in security point of view.
The next commit will replace strncpy() with memcpy(), so let's restore the
original implementation.
4 years ago
Roman Gilg
b36af22c94
backend: move get_drm_fd to public interface
...
The get_drm_fd was made available in an internal header with a53ab146f
. Move it
now to the public header so consumers opting in to the unstable interfaces can
make use of it.
4 years ago
Ryan Farley
b29ac8fbac
util/uuid: replace with util/token, remove libuuid
...
Use 128-bit hexadecimal string tokens generated with /dev/urandom
instead of UUIDs for xdg-foreign handles, removing the libuuid
dependency. Update readme and CI. Closes #2830 .
build: remove xdg-foreign feature
With no external dependencies required, there's no reason not to always
build it. Remove WLR_HAS_XDG_FOREIGN as well.
4 years ago
Simon Ser
5a178c4a23
build: remove wayland-scanner fallback
...
See the Weston discussion [1] for motivation.
[1]: https://gitlab.freedesktop.org/wayland/weston/-/merge_requests/157
4 years ago
Benoit Gschwind
ee3640363e
Document the wlr_output_layout_get function
4 years ago
Kenny Levinsen
d50bbf0bbc
backend/session: Remove logind backend
...
This is instead delegated to libseat.
4 years ago
Stephan Hilb
9f012cac2f
drm: check for PRIME support
...
PRIME support for buffer sharing has become mandatory since the renderer
rewrite. Make sure we check for the appropriate capabilities in backend,
allocator and renderer.
See also #2819 .
4 years ago
Simon Ser
d5105c42e3
build: disable libseat subproject server and man pages
...
When libseat is built as a subproject, we're not interested in
building the server or the man pages.
4 years ago
Simon Ser
1eb38e0015
Remove WLR_HAS_XCB_ERRORS
...
wlroots' dependency on this library doesn't change the features
exposed to compositors. It's purely a wlroots implementation detail.
Thus downstream compositors shouldn't really care about it.
Introduce an "internal_features" dictionary to store the status of
such internal dependencies.
4 years ago
Isaac Freund
78befa59f9
gtk-primary-selection: drop support
...
The standard primary-selection protocol is now widely supported.
4 years ago
Simon Ser
a109a80dca
render: drop support for ellipses
...
For anything more complicated than quads, compositors can easily
ship their own shaders.
Closes: https://github.com/swaywm/wlroots/issues/2759
4 years ago
Simon Ser
9ecfa4343a
render: remove wlr_texture_to_dmabuf
...
This is unused in wlroots, and the use-cases for compositors are
pretty niche since they can access the original DMA-BUF via the
wlr_buffer.
4 years ago
Simon Ser
1cdef8da57
render: drop wlr_renderer_blit_dmabuf
...
It can be replaced with wlr_renderer_bind_buffer. blit_dmabuf is
broken as-is (dies on an assertion).
4 years ago
Simon Ser
1c10079a67
build: bump version to 0.14.0
...
We now bump the version number right after releases, so that a Git
snapshot is not mistaken for a previous version.
References: https://github.com/swaywm/wlroots/issues/2792
4 years ago
Simon Ser
69c71dbc8a
build: bump to v0.13.0
...
References: https://github.com/swaywm/wlroots/issues/2778
4 years ago
zccrs
69e1997ebe
render/egl: check "EGL_KHR_platform_gbm" for EGL gbm platform
...
See the
https://www.khronos.org/registry/EGL/extensions/KHR/EGL_KHR_platform_gbm.txt
example code. On EGL_PLATFORM_GBM_KHR platform, we should be check the
"EGL_KHR_platform_gbm" extension.
Change-Id: Icf11c07c2949841a80b10527fb09987257fbd63b
4 years ago
Simon Ser
8ccb4bbb5f
backend/drm: stop testing for buffer in drm_connector_commit_buffer
...
We now do the test in drm_connector_test, called from
drm_connector_commit.
4 years ago
Simon Ser
d0bf750916
backend/drm: use atomic test-only commits for direct scan-out
...
This allows callers to use wlr_output_test to figure out whether a
buffer can be scanned out prior to committing the output.
4 years ago
Simon Ser
7efc2d05b7
backend/drm: downgrade test-only commit failure log level
...
Let's not clutter the logs with error messages when a test-only
atomic commit fails.
4 years ago
Simon Ser
5088e25eaf
backend/drm: don't set NONBLOCK with TEST_ONLY
...
The kernel ignores NONBLOCK when TEST_ONLY is set. Let's just not
set it, to make it clear it's unused.
4 years ago
Simon Ser
55aaeb25c5
build: use get_variable instead of get_pkgconfig_variable
...
This fixes the following warning:
WARNING: Project targeting '>=0.56.0' but tried to use feature deprecated since '0.56.0': Dependency.get_pkgconfig_variable. use Dependency.get_variable(pkgconfig : ...) instead
4 years ago
Simon Ser
6721444114
build: simplify HAS_LIBUUID definition
...
We can just use to_int() instead of having two if branches.
4 years ago
Simon Ser
e9361e0492
backend/x11: reject DMA-BUFs with flags
...
We cannot scan-out DMA-BUFs with any flag right now.
4 years ago
Simon Ser
6bfbf35618
backend/drm: reject DMA-BUFs with flags
...
We cannot scan-out DMA-BUFs with any flag right now.
4 years ago