05:34 wlb: wayland Merge request !342 closed (protocol: add wl_pointer.warp)
05:39 Riolku: Stupid question. Why do I care about devices being grouped into seats? To me, there exists keyboards and pointers and touch devices. Why does it matter that they have their own seats?
05:41 jadahl: Riolku: for the theoretical use case where multiple people interact with the same display server, each with their own keyboard/mouse pair
06:29 emersion: nice castle daniels :P
06:32 daniels: it’s not mine :(
06:34 emersion: not yet
09:18 axet: hi! i'm tyring to enable waylang and have some issues. first I unable to add custom resolution. i get black screen instead. looks like wayland picking wrong refresh rate from 'video=eDP-1:1366x768@60' gnome showing 60.02 refresh rate and it fails. Same on xrandr mode. I have two refresh rates 60.00 and 60.02 last one fails on xrandr. is here a way to force wayland to use 60.00?
09:19 axet: second issue. i unable to disable touch pad middle key. i have no issues remapping keys on x11. but failed on wayland. Option "ButtonMapping" "1 1 3 4 5 6 7". even using xinput failed.
09:20 axet: 3) no xgamma support
10:14 kennylevinsen: axet: Wayland is a protocol. If you use GNOME, you're using their Wayland server (Mutter). You should ask for help in a GNOME channel.
10:15 axet: thanks. i didn't know this is about protocl! i go there
10:15 kennylevinsen: xrandr, xinput and such are not applicable though - they are configuring X11
10:15 kennylevinsen: But you'll have to ask GNOME for the appropriate replacement :)
10:15 axet: yea. i guess. just using it for refference
10:16 axet: is here a mutter irc?
10:16 kennylevinsen: https://wiki.gnome.org/GettingInTouch/IRC
10:16 axet: ok #gnome
10:23 MrCooper: note that the Matrix rooms are canonical for GNOME, and the IRC bridge isn't working currently
10:27 axet: MrCooper they moved to Matrix you are saying?
10:27 MrCooper: basically yeah
10:31 kennylevinsen: MrCooper: ... did you ack yourself there with "basically yeah" did you respond to yet another unauth'd Matrix user?
10:31 kennylevinsen:thinks this guessing game is getting old
10:32 MrCooper: replying to axet, I'm not on Matrix though, so a reverse issue maybe?
10:33 kennylevinsen: Ah ok then I just read too much into it
11:06 jadahl: axet: #gnome-shell on IRC or matrix. there used to be a bridge but no more
12:25 Fxzxmic: Will wayland no longer have remote rendering support?
12:27 soreau: Fxzxmic: it's not really up to 'wayland' but the compositor, how it will support this
12:28 soreau: but the short answer is, that remote rendering works in many different ways and supported by different compositors and components, differently
12:29 soreau: your best bet is to ask in your compositor support channel
12:29 Fxzxmic: Sorry, I don't quite understand this aspect.
12:31 Fxzxmic: What I'm talking about is like in the X environment, handing over the graphics of a host without a graphics card to a local graphics card for rendering, and then displaying the software interface on the local host.
12:33 Fxzxmic: Just like SSH's X11 forwarding.
12:33 soreau: there is waypipe
12:34 soreau: but you can also run a wayland display server on a headless box and vnc into it where there are graphics
12:35 Fxzxmic: I don't like VNC.
12:36 Fxzxmic: However, I am glad that the feature I mentioned has not been deprecated in the wayland environment.
12:37 axet: hmm i didn't know actually here is waypipe
12:37 axet: nice to know
12:38 MrCooper: "remote X" these days really means "X over SSH" except for some rounding error, and waypipe works mostly the same as that
12:42 Fxzxmic: I don't think so, it can also be done without SSH.
12:55 MrCooper: I'm saying the number of users actually doing so is a rounding error at this point
12:57 soreau: also, it's not really relevant in this channel
12:57 kennylevinsen: also, X forwarding with modern X does not "hand over graphics to a local graphics card for rendering". The remote host renders the image, likely with software rendering, and inefficiently sends pictures...
13:01 kennylevinsen: waypipe works way better
16:14 pitust: so i'm making my own semi-libwayland thing, and i'm really confused about wl_registry.bind
16:14 pitust: the xml says it takes two params, a uint (name) and new_id (id)
16:15 pitust: and so does https://wayland.app/protocols/wayland
16:16 pitust: but if i send that, sway no like
16:17 pitust: also, when i use wldbg to inspect traffic from foot(1), it seems that it uses a completly different frame?
16:18 pitust: name, name as string, name again, new_id
16:18 pitust: in fact WAYLAND_DEBUG=1 also says that
16:20 soreau: what language are you using?
16:23 vyivel: pitust: https://wayland.freedesktop.org/docs/html/ch04.html#sect-Protocol-Wire-Format, see "new_id"
16:29 pitust: oh, thanks!
16:30 pitust: soreau: the best language, i. e. c++
16:30 soreau: basically you want wl_registry_bind(registry, name, interface, version)
16:30 pitust: yep thanks
16:30 pitust: ugh, this is annoying
16:30 pitust: screws with my pretty api
16:31 kennylevinsen: we should have this be on a front-page FAQ
16:31 pitust: this should be noted in every place talking about the wire protoco
16:31 kennylevinsen: it's always the first question from anyone touching the wire format
16:31 pitust: note it here: https://wayland-book.com/protocol-design/wire-protocol.html
16:31 pitust: as well
16:42 vyivel: wayland-book.com should also note that it's not official
16:44 pitust: sure, sure, but it's also very useful
16:44 pitust: and the spec is way easier to find :^)
16:44 pitust: s/easier/harder
17:38 pitust: okay i'm having a new error now!
17:38 pitust: invalid arguments for wl_compositor@4.create_surface
17:39 pitust: wl_compositor.create_surface takes one argument, an object id..
17:39 pitust: and i'm pretty sure i'm not doing the new_id without interface thing here
17:39 pitust: yeah i'm not
17:42 kennylevinsen: pitust: well, you call on the wl_compositor oid and pass the wl_surface new_id
17:42 pitust: ye
17:43 kennylevinsen: picking an invalid oid perhaps?
17:43 pitust: wldbg dumps the correct thing though? "C: wl_compositor@4.create_surface(new id wl_surface@7)"
17:43 pitust: 7 sounds valid
17:43 kennylevinsen: is 7 the lowest unused number?
17:44 pitust: do you have to use the *lowest* unused number?
17:44 pitust: i don't have delete_id yet
17:44 pitust: oh
17:44 pitust: i had a gap
17:49 vyivel: pitust: https://wayland.freedesktop.org/docs/html/ch04.html#sect-Protocol-Creating-Objects
17:50 pitust: "Any ID allocation algorithm that does not maintain this property is incompatible with the implementation in libwayland." heh what?
17:50 pitust: this is a "spec" or "this is what the reference impl does deal with it"
17:51 vyivel: tbh not sure myself lol
17:51 vyivel: if i have libwayland2 which allocates ids randomly is it still wayland
17:52 pitust: okay anyway now i get to "xdg_surface must have a role"
17:52 vyivel: xdg_surface.get_{toplevel,popup}
17:52 pitust: ah
17:52 kennylevinsen: pitust: it's a libwayland-server restriction and therefore spec
17:52 kennylevinsen: it's a protocol error to provide an ID that does not comply
17:54 vyivel: huh outputs were supposed to have "requests to move and change modes" (?)
17:54 vyivel: https://wayland.freedesktop.org/docs/html/pr02.html is my favorite part though
17:55 emersion: lol
17:57 vyivel: https://wayland.freedesktop.org/reviewing.html is also pretty dated, featuring patches by email, Real Names™ and meritocracies
18:13 bl4ckb0ne: nice preface
18:13 bl4ckb0ne: is kristian still involved in wl?
18:13 emersion: nope
18:14 vyivel: anyone up to update the whole website
18:15 emersion: send patches and i'll merge them
18:15 bl4ckb0ne: acknowledge me vyivel
18:15 emersion: ideally before anyone gets the chance to bikeshed :)
18:15 vyivel: unfortunately i found myself unable to write anything longer than three sentences lately
18:16 emersion: but here you just need to delete lines!
18:16 vyivel: i mean if you're fine with wayland.fd.o just being rotating wayland logo then sure
18:17 kennylevinsen: marquee!
18:17 vyivel: with "i am just a freak" playing in the background but "freak" is replaced with "protocol"
18:18 emersion: ship it
18:29 ids1024: Rotating wayland logo, plus a link that says "Wayland Specification" but just does to https://gitlab.freedesktop.org/wayland/wayland/-/tree/main/src
18:30 pitust: accurate
18:31 vyivel: lol true it's faster to open the local copy of libwayland and check what i want
18:31 pitust: my protocol lib seems to work
18:31 pitust: now all i have to do is create a window
18:31 pitust: somehow
18:33 pitust: hmm so i don't get a window for some reason
18:33 kennylevinsen: wl_surface -> xdg_surface -> xdg_toplevel, then commit a buffer from wl_shm
18:34 kennylevinsen: first empty configure after xdg_toplevel to set the role, then commit a buffer in the size you want with some content to make a visible window
18:39 pitust: i'm not getting any configure events
18:40 pitust: code: https://paste.sr.ht/~pitust/f5099bc2f926e078645d1de72f6af5b36308bbe8
18:41 kennylevinsen: you need to cmmit without the buffer first
18:41 kennylevinsen: after applying the xdg_toplevel role
18:41 pitust: ah
18:41 pitust: ==2043195==ERROR: AddressSanitizer: stack-use-after-return on address 0xffff299fe188 at pc 0xaaab3ac7401c bp 0xffffd4156a00 sp 0xffffd4156a18
18:41 pitust: exciting
18:42 kennylevinsen: yeah don't do that
18:42 pitust: at least i build with asan so i can see the error ig
18:43 pitust: i love how the asan stacktrace is like completly unreadable
18:43 pitust: thanks i really wanted to know the error is in std::enable_if<is_invocable_r_v<main::$_2::operator()() const::'lambda0'(unsigned int), void libwl_object::register_event<xdg_surface xdg_surface::on_configure<main::$_2::operator()() const::'lambda0'(unsigned int)>(main::$_2::operator()() const::'lambda0'(unsigned int))::'lambda'(libwl_deser&)>(unsigned int, main::$_2::operator()() const::'lambda0'(
18:44 kennylevinsen: well, that one is mostly on C++
18:45 pitust: thats true
18:47 pitust: okay sway, why is this not an error: 01:35:58.446 [wlr] [render/gles2/texture.c:39] Invalid stride 300 (too small for 4 bytes-per-pixel and width 100)
18:47 pitust: like a hard wayland error
18:47 pitust: oh niceee
18:47 pitust: i have a square on the screen
18:48 vyivel: congrats
18:48 pitust: okay so i guess xdg_toplevel.configure is triggered when the window resizes or something
18:48 vyivel: it's triggered when a compositor wants the toplevel to assume a new state
18:49 vyivel: size, whether it's activated, maximized, fullscreened etc
18:49 pitust: ahh
18:54 pitust: okay so for some reason drawing starts in some super weird place
18:57 pitust: and like i "draw" a window but its not very good
18:57 pitust: oh hmm i should probably damage the surface
18:57 pitust: nope, doesn't help
19:00 kennylevinsen: you know you're not allowed to edit the buffer right
19:01 kennylevinsen: you submit a new buffer with damage explaining how it differs from the previous one
19:01 pitust: yeah sure
19:01 pitust: the buffer never changes
19:01 pitust: i don't even map the buffer!
19:02 kennylevinsen: what do you mean? no buffer == no window
19:02 pitust: of course
19:02 pitust: i have a buffer attached
19:02 pitust: its just not mapped, its some zero bytes in a memfd
19:02 kennylevinsen: ah mmaped, not mapped surface, gotcha
19:03 pitust: but i get this: https://cdn.discordapp.com/attachments/1159299233141248011/1161739791650533396/20231011_19h58m57s_grim.png
19:03 pitust: so the black pixels aren't covering the entire surface
19:03 pitust: oh okay
19:04 pitust: i needed to set the xdg_window's geometry
19:04 pitust: can i manipulate a buffer if it's not the active one?
19:05 pitust: like if i attach another buffer, can i then make changes
19:05 kennylevinsen: once you receive wl_buffer.release
19:05 pitust: ah
19:05 pitust: cool, thanks
19:06 pitust: i guess i should start structuring my code a bit better than a couple of lambdas
19:06 kennylevinsen: but it can take a moment before the buffer is released, and if you render fast you can end up using up to 3 buffer at a time
19:07 kennylevinsen: (for dmabuf in direct scanout, 4 due to some drm details)
19:07 pitust: that's fine i guess
19:07 kennylevinsen: there's also an optimization where some compositors will try to release shm buffers fast so you only need one, but it's optional
19:07 kennylevinsen: if you use wl_surface.frame, you should be able to do with 1-2 most of the time
19:07 pitust: i guess i only care about wlroots
19:08 pitust: since what i *really* want to do is to make my own very bad swaybar clone
19:08 kennylevinsen: we do that optimization
19:08 pitust: cool
19:13 pitust: is there any request which contains two new_id's?
19:18 vyivel: nope
19:18 vyivel: because in c the call would be "struct foo *thing = request()"
19:18 vyivel: can't return two new objects
19:18 pitust: quality bindings generator you got there
19:19 pitust: *my* bindings generator handles this case gracefully anyway
19:19 kennylevinsen: to be fair, if we needed it we'd just make it generate a pointer argument
19:19 kennylevinsen: but we don't
19:20 pitust: yeah fair enough that makes sense