RDP (remote desktop) backend #1578
Conversation
ddevault
commented
Feb 25, 2019
•
edited
edited
- Spin up FreeRDP server
- Allocate headless outputs for each peer
- Send frame updates to clients via RFX
- Send frame updates to clients via NSC
- Send raw frame updates for clients which support neither
- Keyboard input
- Pointer input
- Clean up
55786bd
to
93f9d84
Compare
|
Would be nice to let the compositor allocate the output, so that it can decide to either create a headless one or use an existing one. That would also remove all the OpenGL stuff from the backend. |
|
Hmm, maybe. The way I saw this working out is that the compositor would mirror to the RDP outputs if they wanted to use an existing one. I also like that this lets you transparently add RDP support without any changes to the compositors. |
|
Still unsure whether this should be merged or not. A client with virtual-keyboard + virtual-pointer + virtual-output would probably be better. |
|
I'm starting to wonder if it wouldn't be nice to have both. |
|
In any case, you could use a headless backend inside the RDP backend to avoid having to re-implement I still think the compositor should be able to customize the output if needed, this could be optional. This can be useful for mirroring or remote controlling. |
|
That seems like a nice to have for a future patch. |
|
Note: this backend is better than Weston's because it uses OpenGL (the Weston backend forces the software renderer). |
|
Or it would be if this didn't force llvmpipe for some reason <_< headless backend has the same problem. No luck figuring it out yet. |
|
@ddevault Maybe open a render node fd ( |
|
Maybe? I'm not sure how that works to be honest. Interested in trying a patch? |
That's how the not-yet-merged Weston patch works: https://lists.freedesktop.org/archives/wayland-devel/2017-July/034423.html |
|
I'd first try to read the mesa code though. |
Currently not really. I don't really know how that works either. I just remembered reading about render nodes for unprivileged gpu access without a DRM master for computation and DRI_PRIME. I found this implementation in virgl: https://gitlab.collabora.com/virgl-es/virglrenderer/blob/master/src/virgl_egl_context.c #1114 is probably related. A single DRM backend could be designed that supports physical and virtual outputs if it is run as DRM master. If it is started on a render node, it will only have virtual outputs and be completely headless. |
|
Other idea: use |
Mesa does not support this. |
|
On my machine Can you try with |
|
I walked through the code and it look like surfaceless does try to create a render node: https://gitlab.freedesktop.org/mesa/mesa/blob/master/src/egl/drivers/dri2/platform_surfaceless.c#L358
I did a log as well, looks like r600 is loaded. rootston-rdp.log ( |
|
This is ready for review. It still ends up using llvmpipe on my system, but that can be solved separately. |
|
Addressed @emersion's comments and rebased into a single (changelog-ready) commit. |
|
Thanks! |
|
Can someone explain in simple words how start freerpd with sway? I use remmina i think should be compatible. |
