[Spice-devel] [PATCH spice 16/18] Send current GL scanout to new client
Marc-André Lureau
marcandre.lureau at gmail.com
Tue Dec 15 15:49:30 PST 2015
Signed-off-by: Marc-André Lureau <marcandre.lureau at gmail.com>
---
server/dcc.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/server/dcc.c b/server/dcc.c
index c56ceb6..47084ca 100644
--- a/server/dcc.c
+++ b/server/dcc.c
@@ -445,6 +445,7 @@ void dcc_start(DisplayChannelClient *dcc)
{
DisplayChannel *display = DCC_TO_DC(dcc);
RedChannelClient *rcc = RED_CHANNEL_CLIENT(dcc);
+ QXLInstance *qxl = red_worker_get_qxl(COMMON_CHANNEL(display)->worker);
red_channel_client_push_set_ack(RED_CHANNEL_CLIENT(dcc));
@@ -464,6 +465,16 @@ void dcc_start(DisplayChannelClient *dcc)
red_pipe_add_verb(rcc, SPICE_MSG_DISPLAY_MARK);
dcc_create_all_streams(dcc);
}
+
+ if (qxl->st->scanout.fd) {
+ if (reds_stream_is_plain_unix(rcc->stream) &&
+ red_channel_client_test_remote_cap(rcc, SPICE_DISPLAY_CAP_GL_SCANOUT)) {
+ red_channel_client_pipe_add(rcc, dcc_gl_scanout_item_new(rcc, NULL, 0));
+ dcc_push_monitors_config(dcc);
+ } else {
+ spice_printerr("FIXME: GL not supported on this kind of connection");
+ }
+ }
}
static void dcc_destroy_stream_agents(DisplayChannelClient *dcc)
--
2.5.0
More information about the Spice-devel
mailing list