D23619: [server] Introduce cloning and replication of output devices

Roman Gilg noreply at phabricator.kde.org
Sat Aug 31 21:56:55 BST 2019


romangg created this revision.
romangg added a reviewer: KWin.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
romangg requested review of this revision.

REVISION SUMMARY
  The org_kde_kwin_outputdevice and respective org_kde_kwin_outputconfiguration
  protocols will be extended by events to indicate the current replication and
  clone status of an output device and a request to change the replication.
  
  Here the notion of clones designate outputs sharing the same properties in an
  immutable fahsion. This is mostly dependent on hardware characteristics when
  outputs share a common CRTC. Changes to such an output will inevitably apply to
  all its clones alike. The property is meant mainly to inform clients about
  such a relation.
  
  Replicas on the other side are arbitrary duplications of the image on an
  output on other ones. This is an one-to-many relation allowing one output as
  source of the image, also called the replication source, and arbitrary many
  other outputs as replicas of the replicaiton source. It is expected that the
  compositor has means to facilitate the replication in a sensible way, for
  example by providing black bars to compensate for different aspect ratios.
  
  Besides the protocol description changes and standard client API this patch
  introduces on server side new functions and algorithms to make use of this
  new interface in an efficient way:
  
  - Logical position and size are cached values of the current position and size of the output in compositor space respecting the replication status.
  - The cached clients-scale is the recommended scaling factor sent to clients on this output such that clients on the replication source and all replicas can provide buffers of optimal resolution. It is the ceiled maximum of all width and height quotients between replicas and replication source and the replication source scale itself. When an output is not a replica it always equals the ceiled scale value of the output.
  - The view-geometry provides a recommended geometry, which is cached as well, of positioning the actual viewable area on the output in pixel-coordinates. Using this geometry the aspect ratio of the final image on every replica will be the same one as the one of the replication source. The geometry returned is a rectangle positioned at the origin with size equaling output's mode size when the output is not a replica.

TEST PLAN
  Tested with patches in KWin, libkscreen and KScreen. Autotests in the future.

REPOSITORY
  R127 KWayland

BRANCH
  clone

REVISION DETAIL
  https://phabricator.kde.org/D23619

AFFECTED FILES
  src/client/outputconfiguration.cpp
  src/client/outputconfiguration.h
  src/client/outputdevice.cpp
  src/client/outputdevice.h
  src/client/protocols/output-management.xml
  src/client/protocols/outputdevice.xml
  src/client/registry.cpp
  src/server/outputchangeset.cpp
  src/server/outputchangeset.h
  src/server/outputchangeset_p.h
  src/server/outputconfiguration_interface.cpp
  src/server/outputdevice_interface.cpp
  src/server/outputdevice_interface.h
  src/server/outputmanagement_interface.cpp

To: romangg, #kwin
Cc: kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20190831/f44dda9a/attachment.html>


More information about the Kde-frameworks-devel mailing list