No announcement yet.

Geometric Picking Finally Lands In GNOME/Mutter 3.34 For Lowering CPU Usage

  • Filter
  • Time
  • Show
Clear All
new posts

  • #51
    Originally posted by 144Hz View Post
    Baguy This article is about 3.34. If you want to talk about 3.28 or older. Then you should go and comment on that old stuff.
    I'm not going to argue further, but my original comment was about how it took gnome so long to get up to this point. I think that is well on-topic.


    • #52
      Originally posted by intelfx View Post
      Stupid question incoming. Can someone please explain what "color picking" actually is, and why does Mutter ever need to perform complex work, reading pixels from GPU and what-not, on such a common operation like cursor movement? I was under impression that specifically cursor rendering is considered so fast-path that modern GPUs tend to include special hardware like overlays to offload cursor rendering as much as possible; so what's wrong with Mutter?

      Disclaimer: I'm totally unfamiliar with any kind of graphics programming so I'm likely missing some crucial context and/or detail. ELI5, please.
      Back in the days all windows were rectangular but now windows can have any shape in theory.
      So when you click with your mouse on the screen you have to do some work to find out which window is there...

      Now I think it's something like this, since they already have the graphics of the windows from the actual drawing-windows part, they...
      • setup a special "image"
      • paint each window from the back to the front on top of each other
      • but not the contents but just the shape filled with a different color each
      • read the pixel under the mouse and see what color that was
      • look up which window they painted with that color
      That solves some problems like testing for complex shapes and rounded corners etc.

      Except for the benefits of _not_ doing this anymore mentioned in the article it should also save you some VRAM I guess?