From ccdf7b7c0e91b2249bc488de519f827040c99b7b Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Wed, 26 Jan 2022 19:32:55 +1100 Subject: [PATCH] [host] app: report the full capture name to the client --- host/platform/Windows/capture/DXGI/src/dxgi.c | 8 +++++++- host/src/app.c | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/host/platform/Windows/capture/DXGI/src/dxgi.c b/host/platform/Windows/capture/DXGI/src/dxgi.c index 0f981260..df035c81 100644 --- a/host/platform/Windows/capture/DXGI/src/dxgi.c +++ b/host/platform/Windows/capture/DXGI/src/dxgi.c @@ -64,7 +64,13 @@ static CaptureResult dxgi_releaseFrame(); static const char * dxgi_getName(void) { - return "DXGI"; + if (!this) + return "DXGI"; + + static char name[64]; + snprintf(name, sizeof(name), "DXGI %s", this->backend->name); + + return name; } static void dxgi_initOptions(void) diff --git a/host/src/app.c b/host/src/app.c index 11b14fcb..615c2dab 100644 --- a/host/src/app.c +++ b/host/src/app.c @@ -583,7 +583,7 @@ static bool newKVMFRData(KVMFRUserData * dst) const uint8_t * uuid = os_getUUID(); memcpy(vmInfo.uuid, uuid, 16); - strncpy(vmInfo.capture, app.iface->shortName, sizeof(vmInfo.capture) - 1); + strncpy(vmInfo.capture, app.iface->getName(), sizeof(vmInfo.capture) - 1); const int modelLen = strlen(model) + 1; const KVMFRRecord record =