frame callbacks and sub_surfaces

Pekka Paalanen ppaalanen at gmail.com
Mon Nov 7 09:27:26 UTC 2022


On Sat, 5 Nov 2022 16:14:44 -0700
Joel Winarske <joel.winarske at gmail.com> wrote:

> Okay thanks for the input.  I sorted it out, and it's working great.
> 
> My learning - Simply implement a frame callback for each sub surface and
> base surface, empty or otherwise.  No need for any other commit calls.
> 
> What is the recommended solution for counting frame rate with sub
> surfaces? 

Are you not usually interested about how many times you have re-drawn?
So you'd count have times you draw, subject to what whatever frame rate
throttling you choose to use.

> Does the base surface ever get occluded?

Anything could be occluded or off-screen at any time.

However, if parent surface is completely occluded/off-screen, then that
should not freeze any of its sub-surfaces that are visible, even if
they are in synchronized mode. So I think the implication of that is
that if any sub-surface is visible, then the parent surface should be
reporting frame callbacks and do everything else as if it was visible
too.

A good question, I wonder if anyone tests compositors for that...

I'm not sure if even Weston handles that correctly.

This is not explicitly mandated by the protocol specification IIRC, it's
more about compositors doing what would look right to an end user.


Thanks,
pq
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20221107/09c54277/attachment.sig>


More information about the wayland-devel mailing list