Handling resolution change and rearrangement of displays
Jonas Ådahl
jadahl at redhat.com
Fri Dec 2 09:52:00 UTC 2022
On Fri, Dec 02, 2022 at 12:24:01AM +0100, Alexander Zvegintsev wrote:
> Hello,
>
> I have some questions regarding handling resolution change and rearrangement
> of displays while screen cast session is active.
>
> I can receive current display properties and arrangement in space(x,y, width
> and height of each display) via response from Start <https://flatpak.github.io/xdg-desktop-portal/#gdbus-method-org-freedesktop-portal-ScreenCast.Start>
> method during initialization.
>
>
> 1. But if I change a screen's resolution while streaming is active, I am
> expecting to `on_param_changed <https://gitlab.freedesktop.org/pipewire/pipewire/-/blob/master/doc/tutorial5.c#L43>`
> being called with updated display size(width and height of stream, it won't
> have location of display though), but it does not happen.
>
> Is my expectation is wrong and I just need to create a new session in this
> case?
>
> 2. Another case is the position change of the two screens relative to each
> other(x,y).
>
> One possible way to get changed display arrangement is before mentioned
> parsing of the response of `Start` method.
>
> Is there are any other options available?
Getting the global position and logical size of screen cast streams
other than as part of the initial response to Start isn't yet possible,
but there is a plan for how to make it possible, and that is to
introduce parameters that is part of the PipeWire stream that specifies
this.
This hasn't yet happened yet, but went and created a issue on PipeWire
to track it: https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/2872
Jonas
>
>
> --
> --
> Thanks,
> Alexander.
More information about the wakefield-dev
mailing list