Re: frame callbacks and sub_surfaces

2022-11-04 Thread Pekka Paalanen
On Thu, 3 Nov 2022 15:14:00 -0700
Joel Winarske  wrote:

> Hi pq,
> 
> I was thinking of a more full-featured example using sub surfaces with
> runtime positioning and z-order control.
> 
> That aside I am having an interesting problem.  In case of multiple
> surfaces, I only see the frame event for the last added surface.
> 
> Surface A is behind B and C (tiled), none occluded.
> 
> Here I get a frame callback for B. I'm using the commit pattern from B to
> Base.
> Surface B
> Surface A
> Base
> 
> Adding sub surface C, with registered callbacks for B and C, I only see a
> frame callback for C.  I'm using the commit pattern from C to Base.
> Surface C
> Surface B
> Surface A
> Base
> 
> I don't touch the B callback when the C callback is added.

Please, be more specific about which requests and when you are sending.
From the above, I can guess the wl_surface.commit requests, but I do
not see when exactly you do e.g. wl_surface.frame and on which surface.

> Does anything stand out?

The only guess I have is that you missed this part from
wl_surface.frame specification:

> The notification will only be posted for one frame unless requested
> again.

and

> The object returned by this request will be destroyed by the
> compositor after the callback is fired and as such the client must
> not attempt to use it after that point.

So every time you want to receive a frame callback, you need to create
a new wl_callback object with wl_surface.frame. And every time
wl_callback.done is delivered, you must destroy the wl_callback.

You can also destroy the wl_callback at any time, if you are no longer
interested in it.


Thanks,
pq


pgpx8_XYcXogQ.pgp
Description: OpenPGP digital signature


[ANNOUNCE] wayland-protocols 1.28

2022-11-04 Thread Jonas Ådahl
wayland-protocols 1.28 is now available.

This release includes one new staging protocol:

 * Xwayland shell

This protocol is intended to exclusively be used by Xwayland to allow a
race condition free method for associating an X11 window with a
wl_surface in a compositor, and is intended to replace the old
WL_SURFACE_ID atom based method.


Apart from this, xdg-shell saw some new error codes for already existing
error conditions.



Demi Marie Obenour (4):
  xdg-shell: Replace an HTTP link with HTTPS
  xdg-shell: window menus are optional
  xdg-shell: Add specific errors
  Add xdg-shell.unresponsive error

Jonas Ådahl (1):
  build: Bump version to 1.28

Joshua Ashton (1):
  xwayland_shell_v1: New protocol

git tag: 1.28

https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/1.28/downloads/wayland-protocols-1.28.tar.xz
SHA256: c7659fb6bf14905e68ef605f898de60d1c066bf66dbea92798573dddec1535b6  
wayland-protocols-1.28.tar.xz
SHA512: 
092454c6a7e5cc47729de49e9061fb91dfdc5610859e17c495642806ca14dcfb3850a5d3a7459ddb70b2adb08d2590d4b0f92c3a97600e48598682d59adb102f
  wayland-protocols-1.28.tar.xz
PGP:
https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/1.28/downloads/wayland-protocols-1.28.tar.xz.sig


signature.asc
Description: PGP signature