aboutsummaryrefslogtreecommitdiff
path: root/examples
AgeCommit message (Collapse)Author
2021-07-06move wlr_box from /types to /utilSimon Zeni
2021-07-01Remove unused wlr_list.h includesSimon Ser
2021-06-22Revert "build: workaround for meson disabler object not working with if not"Simon Ser
This reverts commit 9796abccedef881e99d293a2658c4da9466acd88. This Meson issue has been fixed upstream for a while. We require 0.56.0 so we should never hit an unpatched Meson.
2021-05-22Flush events in virtual pointer exampleBrian McKenna
2021-04-20examples/rotation: remove unused includesSimon Zeni
2021-04-20examples: introduce quads exampleSimon Zeni
This examples uses `wlr_render_quad_with_matrix` to render coloured squares on the screen, and uses the rotation to make them spin on their middle.
2021-04-19Stop specifying xkb_rule_namesSimon Ser
If a NULL xkb_rule_names pointer is passed to xkb_keymap_new_from_names, libxkbcommon will default to reading the XKB_* env variables. So there's no need to do it ourselves. Also s/xkb_map_new_from_names/xkb_keymap_new_from_names/ since the latter is more consistent with the returned struct name. [1]: https://xkbcommon.org/doc/current/structxkb__rule__names.html
2021-04-19examples: remove dependency on GLES2 for compositor examplesSimon Ser
Most of the examples had a GLES2 dependency, but weren't using it. Convert multi-pointer to wlr_renderer instead of using directly glClear.
2021-04-19examples: use wlr_output_preferred_modeSimon Ser
2021-04-17render: make GLES2 renderer optionalayaka
Allow selecting whether the GLES2 renderer gets enabled. Co-authored-by: Simon Ser <contact@emersion.fr>
2021-04-16examples/rotation: error out on invalid optionSimon Ser
2021-03-22examples/dmabuf-capture: stop using av_init_packetSimon Ser
It's deprecated in ffmpeg >= 4.4. Closes: https://github.com/swaywm/wlroots/issues/2798
2021-02-23examples: add libdrm partial dependency for compositorsSimon Ser
Fixes: 675bc396583f ("Fix wl_shm_format passed to wlr_texture_from_pixels")
2021-02-23Fix wl_shm_format passed to wlr_texture_from_pixelsSimon Ser
Fixes: 27fba3df4347 ("render: use DRM formats in wlr_texture_from_pixels")
2021-02-14examples: remove wlroots dep from client examplesSimon Ser
There is one exception: layer-shell still uses wlr_log. Would need to convert to fprintf to drop the wlroots dep there. Fixes: 34e7f69d6942 ("examples: remove dependency on wlr_egl from clients")
2021-02-14examples: drop wlr/render/egl.h include from client examplesSimon Ser
We use egl_common.h instead. Fixes: 34e7f69d6942 ("examples: remove dependency on wlr_egl from clients")
2021-02-14examples: drop wlroots dep from egl_common.cSimon Ser
Just use fprintf instead of wlr_log.
2021-02-04examples/egl_common: make attribs constBrandon Dowdy
Make (config, context)_attribs const just to be on the safe side.
2021-01-30examples: remove "major" and "minor" from egl_common.cBrandon Dowdy
Remove "major" and "minor" from egl_common.c as they are not used by the examples that use egl_common.c.
2021-01-29examples: remove dependency on wlr_egl from clientsBrandon Dowdy
The specified clients in this commit used to rely on wlr_egl and some of its related functions in order to render surfaces. This is no longer the case as of this commit.
2021-01-25examples/foreign-toplevel: Add documenation and output selectionfwsmit
2021-01-12layer-shell: allow new values for keyboard-interactivityDaniel Kondor
Value is now an enum with a new value ("on-demand") that compositors can use to allow "normal" keyboard focus semantics regardless of the layer the client surface is on. An error is sent for invalid keyboard interactivity values. The old behavior is retained for clients using the previous version of the protocol. Also adjusted the layer-shell example program to use the new keyboard interactivity options.
2021-01-12render/egl: replace init/finish with create/destroySimon Ser
This ensures wlr_gles2_renderer can properly take ownership of the wlr_egl. Closes: https://github.com/swaywm/wlroots/issues/2612
2021-01-12render/egl: remove support for EGL_NATIVE_VISUAL_IDSimon Ser
Nobody uses it anymore.
2021-01-04examples: request an EGL configSimon Ser
Client examples using wlr_egl would fail with EGL_BAD_CONFIG because they need an EGL config. Set the config attribs to a non-NULL value to make sure wlr_egl creates an EGL config. Fixes: 037710b1d428 ("render/egl: support config-less wlr_egl")
2021-01-04examples: remove visual for EGL_PLATFORM_WAYLAND_EXTSimon Ser
The Wayland EGL platform doesn't have visuals.
2020-12-30Remove wlr_create_renderer_func_tSimon Ser
This callback allowed compositors to customize the EGL config used by the renderer. However with renderer v6 EGL configs aren't used anymore. Instead, buffers are allocated via GBM and GL FBOs are rendered to. So customizing the EGL config is a no-op.
2020-12-25Stop using wlr_texture_get_sizeSimon Ser
Just use wlr_texture.{width,height} directly.
2020-12-13build: move wayland-egl dependency to examples/Simon Ser
Now that the Wayland backend has moved to wlr_swapchain, only client examples use the dependency. Stop linking against wayland-egl in the wlroots library.
2020-11-11Remove unneeded includes from wlr_input_device.hIsaac Freund
This uncovered many places where we were using things without directly including them.
2020-11-11Replace wlr_key_state with wl_keyboard_key_stateIsaac Freund
There's no reason to have duplicate enums
2020-10-18foreign-toplevel-management: report parent toplevelDaniel Kondor
Based on the wlr-protocols PR: https://github.com/swaywm/wlr-protocols/pull/52
2020-10-11examples: use `perror` instead of `fprintf` GNU %m `printf` extensionTudor Brindus
2020-08-31examples/dmabuf-capture: add extra roundtrip for wl_output listenerSimon Ser
This example was relying on wl_display_dispatch being enough to fetch output information. This worked by chance. Add an explicit wl_display_roundtrip. Other examples don't setup wl_output listeners, so they should be fine. Fixes: 297354f84772 ("Remove unnecessary wl_display_dispatch calls") Closes: https://github.com/swaywm/wlroots/issues/2386
2020-08-24Remove unnecessary wl_display_dispatch callsSimon Ser
wl_display_roundtrip already takes care of dispatching the display.
2020-08-14examples/simple: use wlr_renderer instead of GLSimon Ser
2020-08-14examples/simple: use wlr_output_preferred_modeSimon Ser
2020-07-28examples: remove unnecessary gles2.h importsRouven Czerwinski
2020-07-21Fix typosAntonin Décimo
2020-07-08examples/input-method-keyboard-grab: new examplexdavidwu
2020-07-06examples: fix improper use of `free`j-n-f
Closes #2303
2020-07-01examples: screencopy-dmabuf: Fix y-inversionAndri Yngvason
2020-06-20examples/pointer: fix wlr_renderer_end call orderSimon Ser
Calling wlr_renderer_end after wlr_output_commit would make an assertion fail.
2020-06-11examples/fullscreen-shell: stop advertising linux-dmabuf unconditonallySimon Ser
Remove the wlr_linux_dmabuf_v1_create call. wlr_renderer_init_wl_display will take care of creating the linux-dmabuf global if the OpenGL implementation supports it.
2020-06-11examples/screencopy-dmabuf: call strncpy with maxlen - 1Simon Ser
The original code wasn't wrong since we were manually writing a null byte anyway, but this makes GCC happy. Closes: https://github.com/swaywm/wlroots/issues/2273
2020-06-08examples: Add screencopy-dmabuf exampleAndri Yngvason
2020-05-20examples: make output-power-management oneshot by defaultIlia Bozhinov
2020-05-01examples/dmabuf-capture: use getoptSimon Ser
This makes it a little bit less annoying to provide the right arguments. All options have reasonable defaults.
2020-04-21build: use dicts instead of get_variableSimon Ser
Closes: https://github.com/swaywm/wlroots/issues/1963
2020-03-25Prevent memory leak in copypaste of the screencopy exampleRabit
If someone want to use screencopy as is processing multiple screenshots - it could be hard to find this issue with shm.