zero to window - wayland client

Поділитися
Вставка
  • Опубліковано 24 гру 2024

КОМЕНТАРІ • 60

  • @meerkat22
    @meerkat22 11 місяців тому +8

    Excellent tutorial! I lost it every time you yelled f**k when the compiler complained

  • @ivhacks
    @ivhacks 28 днів тому

    Very helpful, thank you! The fact that you were able to do this so smoothly live is really impressive

  • @godnyx117
    @godnyx117 8 місяців тому +6

    Thank you so much! This will come in handy in the future when I'll try to build my own GUI library! Please, consider updating in 2-3 years, in case Wayland changes its architecture!

  • @Shxvang
    @Shxvang 9 місяців тому +3

    Really good tutorial, looking forward for more wayland tutorials from you

  • @ivythegreat2408
    @ivythegreat2408 2 роки тому +16

    Very nice! I tried writing my own wayland client without using libwayland, but unfortunately the official spec basically assumes you are using libwayland. So in some more complex requests such as wl_shm.create_pool the spec doesn't actually describe the wire messages only the call into libwayland, so its a pain to dig through the source to figure it out. I don't think that's a good thing since libwayland should just be a reference implementation of the spec, not the spec itself, but oh well I guess most people would just prefer to use it anyways.

    • @ivythegreat2408
      @ivythegreat2408 2 роки тому +1

      Cool channel though, I absolutely agree with your philosophy on the value of not being afraid to just build things from scratch and really understand how they work.

    • @mgord9518
      @mgord9518 11 місяців тому

      What was your use case for not using libwayland? Learning the wire protocol, wanting a static build or something else?

  • @AndersJackson
    @AndersJackson Рік тому +9

    The X11 is divided in two parts, the client and server. And those parts doesn't need to be running on the same machine. The window manager, is just an ordinary program, that can control and place other clients windows. So a window manager can be written in about 200 lines of code.
    So basically, to decide what window should be positioned on the screen or not, is decide by window manager, you don't need any support from the client. In Wayland you MUST have support from the client to be able to iconify or maximize a client window. If the client is sleeping, you can't iconify the window (basically like MS Windows). As long as the WM client runs, X11 can move windows around without support from the client.

    • @rogo7330
      @rogo7330 Рік тому +1

      Aren't client in Wayland supposed to just render something into the memory and that's all? In terms of server it should just be "not render this window to the actual screen", right?

  • @vl01s
    @vl01s Рік тому +3

    Thanks for sharing this, indeed very useful for a beginner like me. I really appreciate it.

  • @aaronruinslives
    @aaronruinslives Рік тому +3

    What i want to know is where you learn all of these different things because obviously i wont get very far only watching videos

    • @pemifo260
      @pemifo260 5 місяців тому +2

      I’m not an expert either but I’m guessing that is reading hours and hours of documentation, searching and scraping the web in the forums. Lots of trial and error. Patience and persistence.

  • @andrewkaster4033
    @andrewkaster4033 Рік тому

    On a modern kernel, can you use memfd instead of shm?

  • @scottdrake5159
    @scottdrake5159 11 місяців тому +1

    Worked through it, highly recommend. Great walkthrough. I hope others find this, it should be linked in the fd.o docs along with the book. Nice work! Thank you.

  • @انامسلموكفى
    @انامسلموكفى 5 місяців тому

    I need to run a c# Desktop application using weston on ubuntu??

  • @allanwind295
    @allanwind295 10 місяців тому +2

    Your color scheme makes it hard to read your code (#include is near invisible).

  • @TheInvisableSmoke
    @TheInvisableSmoke Рік тому +1

    Great video, and explanation.

  • @egoros7
    @egoros7 9 місяців тому

    how are you theming your setup???

  • @sergeymorozov5592
    @sergeymorozov5592 2 роки тому +1

    TY man, so long video, but so interesting!

  • @miko007
    @miko007 11 місяців тому +2

    the thing people still do not seem to understand is, that "wayland" actually does nothing. it does not exist, it is not a piece of software. its a specification, and just that. wayland describes how you talk to _A_ compositor, it is not one of on its own. its just the description of an api.
    basically the complete introduction of this video is factually wrong.

    • @willth8
      @willth8  10 місяців тому +1

      Wayland exists as a server for the compositor. You are correct to an extent that Wayland is almost entirely a specification for communication between the individual applications and the compositor, and I shouldn't have said "Wayland is a compositor", though I'd still argue that Wayland "exists" and "runs" as the network of the clients and servers.

  • @low-key-gamer6117
    @low-key-gamer6117 9 місяців тому +1

    Are you using external libs like wlroots?

    • @godnyx117
      @godnyx117 8 місяців тому +2

      "wlroots" is used to create a Wayland compositor, not a client.

  • @spongythecake
    @spongythecake 9 місяців тому +1

    I'm the thousandth subscriber!

  • @delmarhollenbach
    @delmarhollenbach 18 днів тому

    Sat, December 7. 12:41AM.

  • @IceQub3
    @IceQub3 8 місяців тому

    amazing video

  • @testeryz680
    @testeryz680 10 місяців тому +1

    can relate too much @ 29:08

    • @godnyx117
      @godnyx117 8 місяців тому

      Hahahaha! Me too! The language I design will have no imports and everything will be automatically searched ;)

  • @Turjak_art
    @Turjak_art Рік тому +1

    Will next time zoom in or take a larger font it's terrible I need a magnifier to see that sh**

  • @delicious_seabass
    @delicious_seabass Рік тому +25

    It's funny, as bad as X11 is, somehow Wayland's API manages to be 10x more incomprehensible. An hour and 20 mins to set up a not even a fully featured window is ridiculous. The state of programming is depressing.

    • @an0nsaiko890
      @an0nsaiko890 Рік тому +10

      Well it would clearly be easier if he used a toolkit like GTK, but the point of the video is to show how the Wayland protocol is used under the hood.

    • @plasmahvh
      @plasmahvh Рік тому +3

      @@an0nsaiko890 and it's not good. 15 years of development and it's still not ready for most people. ridiculous

    • @an0nsaiko890
      @an0nsaiko890 Рік тому +3

      @@plasmahvh I would say that it's not as bad as it may seem. It clearly lacks some features which are getting worked on. I believe the lack of wide adaptation is a huge reason for its slow development and bugs. It was only this year that mainline distros announced pure use of Wayland (no longer being the second option)

    • @thebatchicle3429
      @thebatchicle3429 Рік тому +14

      Having an easier API doesn’t make your protocol or server better

    • @tommasobonvicini7114
      @tommasobonvicini7114 Рік тому

      @@thebatchicle3429easier and comprehensible are two different things.

  • @vtvitus
    @vtvitus 10 місяців тому

    f* callback hell

  • @dejanlekic5513
    @dejanlekic5513 2 місяці тому

    zero to window would be without wayland-client...

  • @leonader9465
    @leonader9465 Рік тому +3

    Could you speak up a little?

    • @vsz-z2428
      @vsz-z2428 11 місяців тому +4

      crank the vol boy

  • @ps5hasnogames55
    @ps5hasnogames55 10 місяців тому +2

    80 minutes for a barely functional window 😂 Wayland is a joke!

    • @mazazaza11
      @mazazaza11 Місяць тому +1

      well winapi is worse honestly

    • @shallex5744
      @shallex5744 5 днів тому

      as it should be