1. 10 Jul, 2020 2 commits
  2. 08 Jul, 2020 9 commits
    • Jonas Ådahl's avatar
    • Jonas Ådahl's avatar
      screen-cast/src: Record follow up frame after timeout · 9bab8e87
      Jonas Ådahl authored
      During animation or other things that cause multiple frames in a row
      being painted, we might skip recording frames if the max framerate is
      Doing so means we might end up skipping the last frame in a series,
      ending with the last frame we sent was not the last one, making things
      appear to get stuck sometimes.
      Handle this by creating a timeout if we ever throttle, and at the time
      the timeout callback is triggered, make sure we eventually send an up to
      date frame.
      This is handle differently depending on the source type. A monitor
      source type reports 1x1 pixel damage on each view its monitor overlaps,
      while a window source type simply records a frame from the surface
      directly, except without recording a timestamp, so that timestamps
      always refer to when damage actually happened.
    • Jonas Ådahl's avatar
    • Jonas Ådahl's avatar
      screen-cast/src: Make record functions return an error when failing · 047da80c
      Jonas Ådahl authored
      Now that we don't use the record function to early out depending on
      implicit state (don't record pixels if only cursor moved for example),
      let it simply report an error when it fails, as we should no longer ever
      return without pixels if nothing failed.
    • Jonas Ådahl's avatar
      screen-cast: Let the reason for recording determine what to record · 882967d3
      Jonas Ådahl authored
      E.g. we'll have pointer movement that, if no painting is already
      scheduled, should only send new cursor metadata without any new pixel
      buffer. When this happens, tell next step to not record the pixels if
      this was the case, instead of having it rediscover this itself.
      Related: #1323
    • Jonas Ådahl's avatar
      screen-cast/src: Add flag to maybe_record() · cea0722e
      Jonas Ådahl authored
      Will later be used to make recording avoid recording actual pixel
      content if e.g. only the cursor moved.
    • Jonas Ådahl's avatar
    • Jonas Ådahl's avatar
      screen-cast-src: Make the two record vfuncs more similarly named · 7b35ed8c
      Jonas Ådahl authored
      Both do more or less the same but with different methods - one puts
      pixels into a buffer using the CPU, the other puts pixels into a buffer
      using the GPU.
      However, they are behaving slightly different, which they shouldn't.
      Lets first address the misleading disconnect in naming, and later we'll
      make them behave more similarly.
    • Daniel van Vugt's avatar
      background: Use NEAREST filtering when the texture is the monitor resolution · ecaaccb0
      Daniel van Vugt authored
      That was obviously always the intention, but it didn't work when the
      display was scaled. My 3840x2160 monitor with a 3840x2160 texture was
      being rendered with LINEAR filtering.
      It seems the `force_bilinear` flag was TRUE when it should be FALSE.
      Because a texture area that's an integer fraction of the texture
      resolution is still a perfect match when that integer is the monitor
      scale. We were also getting:
      `meta_actor_painting_untransformed (fb, W, H, W, H, NULL, NULL) == FALSE`
      when the display was scaled. Because the second W,H was not the real
      sampling resolution. So with both of those issues fixed we now get
      NEAREST filtering when the texture resolution matches the resolution it's
      physically being rendered at.
      Note: The background texture actually wasn't equal to the physical monitor
      resolution prior to January 2020 (76240e24). So it wasn't possible to do
      this before then. Since then however, the texture resolution is always
      equal to the physical monitor resolution.
  3. 07 Jul, 2020 7 commits
    • Florian Müllner's avatar
      Bump version to 3.37.3 · 30d9d196
      Florian Müllner authored
      Update NEWS.
    • Florian Müllner's avatar
      tests/stage-view: Keep old stage views alive on hotplug · 65aa4764
      Florian Müllner authored
      Otherwise we cannot reliably compare them to the new post-hotplug
    • verdre's avatar
      clutter/actor: Add position argument to allocate_preferred_size() · 03d177cf
      verdre authored
      Make clutter_actor_allocate_preferred_size() convenient to use from
      layout managers by not "automatically" honouring the fixed position of
      the actor, but instead allowing to pass a position to allocate the
      actor at.
      This way we can move the handling of fixed positions to
      ClutterFixedLayout, the layout manager which is responsible for
      allocating actors using fixed positions.
      This also makes clutter_actor_allocate_preferred_size() more similar to
    • verdre's avatar
      clutter/actor: Add API to get fixed position · dfa235aa
      verdre authored
      It's currently a bit hard to get the fixed position of an actor. It can
      be either done by using g_object_get() with the "fixed-x"/"fixed-y"
      properties or by calling clutter_actor_get_position().
      Calling clutter_actor_get_position() can return the fixed position, but
      it might also return the allocated position if the allocation is valid.
      The latter is not the best behavior when querying the fixed position
      during an allocation, so introduce a new function
      clutter_actor_get_fixed_position() which always gets the fixed position
      and returns FALSE in case no fixed position is set.
    • Robert Mader's avatar
      window-actor/wayland: Remove custom get_paint_volume() vfunc · d722e59a
      Robert Mader authored
      It doesn't take all children - subsurfaces in this case - into
      account, thus creating glitches if subsurfaces extend outside
      of the toplevel surface.
      Further more it doesn't seem to serve any special purpose - it was
      added in f7315c9a, a pretty big commit, and no discussion was
      started about the code in question. So it was likely just overlooked
      in the review process.
      Closes #873
      Closes #1316
    • Daniel van Vugt's avatar
      background-content: Mipmap background texture rendering · 32dbcd93
      Daniel van Vugt authored
      gnome-shell displays workspace previews at one tenth scale. That's a
      few binary orders of magnitude so even using a LINEAR filter was
      resulting in visible jaggies. Now we apply mipmapping so they appear
      As an added bonus, the mipmaps used occupy roughly 1% the memory of
      the original image (0.1 x 0.1 = 0.01) so they actually fit into GPU/CPU
      caches now and rendering performance is improved. There's no need to
      traverse the original texture which at 4K resolution occupies 33MB,
      only a 331KB mipmap.
      In my case this reduces the render time for the overview by ~10%.
      Closes: gnome-shell#1416
    • Daniel van Vugt's avatar
      cogl-texture-2d: Flush the journal before mipmapping · 3a474556
      Daniel van Vugt authored
      In the case of indirect rendering like the first frame to use mutter's
      background wallpaper:
        Texture_A -> FBO_B (Texture_B) -> FBO_C (screen)
      we would be trying to render the contents of both FBO_B and FBO_C in
      the same flush, before the contents of Texture_A had made it to FBO_B.
      So when FBO_C wants to use mipmaps of Texture_B they didn't exist yet
      and appeared all black. And the blackness would remain for subsequent
      frames as cogl has now decided the mipmaps of FBO_B are no longer
      "dirty" and don't need refreshing:
        FBO_B (Texture_B) (mipmaps_dirty==FALSE but black) -> FBO_C (screen)
      We must flush FBO_B before referencing Texture_B for use in rendering
      FBO_C. This only happens when Texture_A changes (e.g. when the user
      changes their background wallpaper) so there's no ongoing performance
      penalty from this flush.
  4. 06 Jul, 2020 3 commits
    • verdre's avatar
      clutter/actor: Pass stage as user_data when unrealizing · 249274c6
      verdre authored
      We can avoid having to get the stage again for every child of the
      subtree we're unrealizing by getting the stage once and passing it as
      user_data to the callbacks.
    • verdre's avatar
      clutter/actor: Remove actors from shallow relayout list when unrealizing · ae83a61e
      verdre authored
      With the introduction of the shallow relayout mechanism another small
      but severe regression sneaked into our layout machinery: We might
      allocate an actor twice during the same allocation cycle, with one
      allocation happening using the wrong parent.
      This issue happens when reparenting an actor from a NO_LAYOUT parent to
      a non-NO_LAYOUT parent, in particular it triggered a bug in gnome-shell
      when DND reparents a child from the NO_LAYOUT uiGroup to the overviews
      Workspace actor after a drag ended. The reason the issue happens is the
      following chain of events:
      1. child of a NO_LAYOUT parent queues a relayout, this child is added to
      the priv->pending_relayouts list maintained by ClutterStage
      2. child is reparented to a different parent which doesn't have the
      NO_LAYOUT flag set, another relayout is queued, this time a different
      actor is added to the priv->pending_relayouts list
      3. the relayout happens and we go through the pending_relayouts list
      backwards, that means the correct relayout queued during 2. happens
      first, then the old one happens and we simply call
      clutter_actor_allocate_preferred_size() on the actor, that allocation
      overrides the other, correct one.
      So fix that issue by adding a method to ClutterStage which removes
      actors from the pending_relayouts list again and call this method as
      soon as an actor with a NO_LAYOUT parent is detached from the stage.
      With that in place, we can also remove the check whether an actor is
      still on stage while looping through pending_relayouts. In case
      something else is going wrong and the actor is not on stage,
      clutter_actor_allocate() will warn anyway.
    • Andre Klapper's avatar
      Fix broken markup in Hausa UI translation · 826573cc
      Andre Klapper authored
  5. 03 Jul, 2020 2 commits
  6. 02 Jul, 2020 17 commits