Simon Ser
a3ec65ef06
Switch to vendored protocol
...
We'll implement some more features on top of input-method, so let's
incubate our own protocol for now. We'll give feedback upstream
once we've experimented a bit with this approach.
The protocol is minimal: it just includes the features needed for
gamescope. It's always easier to add new requests/events than to
change existing ones.
2021-10-08 22:55:01 -07:00
Simon Ser
ad26899b20
ime: reset keymap after sending emulated key events
...
This fixes SteamOS' virtual keyboard.
2021-10-08 22:55:01 -07:00
Simon Ser
6d2b53197e
ime: introduce keycode allow-list
...
Some clients (Chromium…) assume keycodes are always coming from
evdev, and interpret e.g. KEY_ESC directly without using the keymap.
2021-10-08 22:55:01 -07:00
Simon Ser
2ba6eefad8
ime: check for xkb_keysym_get_name errors
2021-10-08 22:55:01 -07:00
Simon Ser
6f26dae77e
ime: send void keysym before key sequence
...
This works around Chromium issues.
2021-10-08 22:55:01 -07:00
Simon Ser
880c87f4c5
ime: disable key repeat
...
Just in case.
2021-10-08 22:55:01 -07:00
Simon Ser
97623694dc
ime: remove unicode keysym name workaround
...
It seems like xkb_keysym_get_name behaves as expected now.
2021-10-08 22:55:01 -07:00
Simon Ser
49da53db55
Implement a subset of input-method-unstable-v2
...
This allows a Wayland client to send arbitrary UTF-8 text to the
currently focused X11 client. Useful for virtual keyboards.
We generate a keymap on-the-fly suitable for the text to type.
2021-10-08 22:55:01 -07:00
Simon Ser
4c659c36bf
Upgrade libliftoff
2021-10-08 13:47:34 +02:00
Simon Ser
c87dd2ef5c
Drop loadargbcursor
...
This is now built-in in gamescope.
2021-10-06 18:48:47 +02:00
Pierre-Loup A. Griffais
39c9e93e0c
Make default touch mode configurable.
2021-10-04 15:00:29 -07:00
Simon Ser
a5a31d46e3
Upgrade libliftoff
2021-09-30 11:22:40 +02:00
Simon Ser
21b263768f
rendervulkan: order formats with alpha first
...
This allows the cursor to be exported as an ARGB8888 buffer suitable
for the cursor plane.
2021-09-29 19:02:18 +02:00
Simon Ser
f55106a344
drm: reset alpha prop on shutdown
2021-09-27 12:42:33 +02:00
Simon Ser
e29e375904
sdlwindow: make most variables static
2021-09-21 11:00:51 +02:00
Simon Ser
14c4b70419
build: clone stb with depth=1
...
We don't need to fetch full Git history.
2021-09-16 12:07:53 +02:00
Simon Ser
a15ea54ca3
ci: turn on auto features
...
Ensures a feature doesn't get auto-disabled because a dep isn't
found.
2021-09-15 20:02:47 +02:00
Joshua Ashton
50f695591d
rendervulkan: Force nearest filtering for non-scaled and integer offset things
...
No reason to do linear filtering otherwise.
2021-09-15 10:58:38 -07:00
Joshua Ashton
b46cc14025
rendervulkan: Use textureLod()
...
May as well.
2021-09-15 10:58:38 -07:00
Joshua Ashton
320a23220a
rendervulkan: Sample at texel centers
...
I missed adding this back in when I did the PR that was meant to fix this when I was debugging... Oops.
2021-09-15 10:58:38 -07:00
Simon Ser
3b2c8995a0
ci: fix meson invocation
2021-09-15 19:07:06 +02:00
Simon Ser
0d8afd8e51
ci: turn on werror
2021-09-15 19:03:37 +02:00
Simon Ser
1cf749c43b
build: ensure wlroots has been built with libinput support
2021-09-15 18:57:44 +02:00
Simon Ser
0687d241a1
build: simplify have_xwayland check
2021-09-15 18:55:39 +02:00
Simon Ser
033695da64
build: disable unused wlroots backends and renderers
2021-09-15 18:44:36 +02:00
Jan Beich
12bff15700
wlserver: hide remaining pipewire stuff with -Dpipewire=disabled
...
src/wlserver.cpp:511:13: warning: unused function 'create_gamescope_pipewire' [-Wunused-function]
static void create_gamescope_pipewire( void )
^
2021-09-15 18:42:12 +02:00
Jan Beich
5548b29521
wlserver: compare using larger type on 32-bit architectures
...
src/wlserver.cpp:430:16: warning: comparison of integers of different signs: 'long' and 'uint32_t' (aka 'unsigned int') [-Wsign-compare]
if (s->wl_id == id && s->wlr == nullptr)
~~~~~~~~ ^ ~~
2021-09-15 18:42:12 +02:00
Jan Beich
04fd7ed5b7
drm: adjust printf format modifiers for 32-bit architectures
...
src/drm.cpp:187:50: warning: format specifies type 'unsigned long' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Wformat]
drm_verbose_log.debugf("page_flip_handler %lu", flipcount);
~~~ ^~~~~~~~~
%llu
src/drm.cpp:777:44: warning: format specifies type 'unsigned long' but the argument has type 'uint64_t' (aka 'unsigned long long') [-Wformat]
drm_verbose_log.debugf("flip commit %lu", (uint64_t)g_DRM.flipcount);
~~~ ^~~~~~~~~~~~~~~~~~~~~~~~~
%llu
2021-09-15 18:42:12 +02:00
Simon Ser
7d108448b1
Improve unknown option error message
...
The stdlib will already print an error message. Let's just mention
--help.
2021-09-15 13:40:59 +02:00
Simon Ser
5849b6c14e
Forbid duplicate short options
...
Just make sure we don't define two flags with the same letter.
2021-09-15 13:38:38 +02:00
Simon Ser
27cff4e41b
wlserver: drop headless backend
...
Saves us the GLES2 renderer init.
2021-09-15 13:35:42 +02:00
Simon Ser
a480fe81fe
Drop VulkanRenderer_t.parent
...
We don't need the wlroots parent GLES2 renderer anymore.
2021-09-15 13:35:42 +02:00
Simon Ser
2772a17f22
Implement wlr_renderer_impl.get_drm_fd
...
This depends on VK_EXT_physical_device_drm.
2021-09-15 13:35:42 +02:00
Simon Ser
92c6823897
wlserver: let wlr_renderer init the DMA-BUF Wayland protocols
...
wlr_renderer_init_wl_display will automatically init the suitable
Wayland protocols.
2021-09-15 13:35:42 +02:00
Simon Ser
9593ef0bfe
build: bump wlroots version requirement
2021-09-15 13:35:42 +02:00
Simon Ser
ae7fcc5ba7
wlserver: get wlr_buffer from VulkanWlrTexture_t
...
This side-steps wlr_client_buffer and ensures we get access to the
underlying buffer. This allows us to call
wlr_buffer_begin_data_ptr_access to upload shm textures.
2021-09-15 13:35:42 +02:00
Simon Ser
0bbecd7e90
Extract fence from Vulkan texture if buffer is shm
2021-09-15 13:35:42 +02:00
Simon Ser
118d8213e4
rendervulkan: implement wlr_renderer_impl.texture_from_buffer
2021-09-15 13:35:42 +02:00
Simon Ser
db1ffbe2e4
rendervulkan: remove wlr_renderer_impl.init_wl_display
...
We don't need EGL_bind_wayland_display anymore.
2021-09-15 13:35:42 +02:00
Simon Ser
6fbabb94b3
rendervulkan: build list of supported wl_shm formats
2021-09-15 13:35:42 +02:00
Simon Ser
a325cf193b
Use wlroots' wl_drm implementation
...
wl_drm is not available on Vulkan.
References: https://github.com/swaywm/wlroots/pull/2708
2021-09-15 13:35:42 +02:00
Simon Ser
123df9006f
rendervulkan: implement wlr_renderer_impl.get_render_buffer_caps
2021-09-15 13:35:42 +02:00
Simon Ser
d13d19981b
rendervulkan: drop wlr_renderer_impl.render_ellipse_with_matrix stub
...
This has been removed from wlroots upstream.
2021-09-15 13:35:42 +02:00
Simon Ser
332f261c35
drm: generalize find_drm_node_by_devid for render nodes
...
We'll use this to open the DRM render node from a VkPhysicalDevice.
2021-09-15 12:12:06 +02:00
Bas Nieuwenhuizen
83eae082fa
Warning fix
2021-09-14 17:29:51 -07:00
Bas Nieuwenhuizen
e510af1b7e
Add a proper release barrier for modifier based images when not nested.
...
RADV does retiling in that barrier. Still hinky overall but this fixes
using compositing with DCC compressed images on RADV.
2021-09-14 17:22:07 -07:00
Joshua Ashton
143176acb1
Fix return value when SDL fails initialization
2021-09-14 17:01:42 -07:00
Joshua Ashton
ce87bf1b76
Init format info after initializing DRM
...
Otherwise all our modifiers/formats and stuff are garbage.
Fixes : #269
2021-09-14 17:01:42 -07:00
Pierre-Loup A. Griffais
8e75287454
steamcompmgr: more GAMESCOPECTRL work
2021-09-14 16:29:42 -07:00
Simon Ser
2eb520bc17
Fix BIsNested return type
2021-09-14 18:36:27 +02:00