Skip to content
  • Oleg Chernovskiy's avatar
    Add Remote Access interface to KWayland · 5116fe0c
    Oleg Chernovskiy authored
    Summary:
    This commit adds an interface bridge from KWin to KRfb. The purpose of
    this protocol is to pass a GBM fd of currently displayed buffer from
    KWin. The buffer is expected to be fully drawn once it is passed.
    
    Related to D1230
    
    Test Plan:
    ********* Start testing of RemoteAccessTest *********
    Config: Using QtTest library 5.6.0, Qt 5.6.0 (x86_64-little_endian-lp64 shared (dynamic) release build; by GCC 6.1.1 20160501)
    PASS   : RemoteAccessTest::initTestCase()
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-client: Connected to Wayland server at: "kwayland-test-remote-access-0"
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-client: Wayland Interface:  wl_shm / 1 / 1
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-client: Wayland Interface:  org_kde_kwin_remote_access_manager / 2 / 1
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-server: Server buffer sent: fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-client: Got buffer, server fd: 15
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-server: Remote buffer returned, client 4 , id 0 , fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-server: Buffer released, fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseSingle() kwayland-client: Buffer released
    PASS   : RemoteAccessTest::testSendReleaseSingle()
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Connected to Wayland server at: "kwayland-test-remote-access-0"
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Wayland Interface:  wl_shm / 1 / 1
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Wayland Interface:  org_kde_kwin_remote_access_manager / 2 / 1
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-server: Server buffer sent: fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Got buffer, server fd: 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Got buffer, server fd: 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-server: Remote buffer returned, client 4 , id 0 , fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-server: Remote buffer returned, client 5 , id 0 , fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-server: Buffer released, fd 15
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Buffer released
    QDEBUG : RemoteAccessTest::testSendReleaseMultiple() kwayland-client: Buffer released
    PASS   : RemoteAccessTest::testSendReleaseMultiple()
    QDEBUG : RemoteAccessTest::testSendClientGone() kwayland-client: Connected to Wayland server at: "kwayland-test-remote-access-0"
    QDEBUG : RemoteAccessTest::testSendClientGone() kwayland-client: Wayland Interface:  wl_shm / 1 / 1
    QDEBUG : RemoteAccessTest::testSendClientGone() kwayland-client: Wayland Interface:  org_kde_kwin_remote_access_manager / 2 / 1
    QDEBUG : RemoteAccessTest::testSendClientGone() kwayland-server: Server buffer sent: fd 15
    QDEBUG : RemoteAccessTest::testSendClientGone() kwayland-server: Buffer released, fd 15
    PASS   : RemoteAccessTest::testSendClientGone()
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-client: Connected to Wayland server at: "kwayland-test-remote-access-0"
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-client: Wayland Interface:  wl_shm / 1 / 1
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-client: Wayland Interface:  org_kde_kwin_remote_access_manager / 2 / 1
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-server: Server buffer sent: fd 15
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-client: Got buffer, server fd: 15
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-client: Buffer released
    QDEBUG : RemoteAccessTest::testSendReceiveClientGone() kwayland-server: Buffer released, fd 15
    PASS   : RemoteAccessTest::testSendReceiveClientGone()
    PASS   : RemoteAccessTest::cleanupTestCase()
    Totals: 6 passed, 0 failed, 0 skipped, 0 blacklisted
    ********* Finished testing of RemoteAccessTest *********
    
    Reviewers: graesslin, davidedmundson, romangg
    
    Reviewed By: davidedmundson, romangg
    
    Subscribers: jtamate, jgrulich, romangg, ngraham, alexeymin, #frameworks, davidedmundson, plasma-devel
    
    Tags: #plasma_on_wayland, #frameworks
    
    Maniphest Tasks: T5653, T7785
    
    Differential Revision: https://phabricator.kde.org/D1231
    5116fe0c