From f633c63d51e148b790fba6c985b72b78439048eb Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Wed, 13 Dec 2017 04:47:28 +1100 Subject: [PATCH] [host] added support for cursor pitch --- host/Capture/DXGI.cpp | 1 + host/ICapture.h | 1 + host/Service.cpp | 1 + 3 files changed, 3 insertions(+) diff --git a/host/Capture/DXGI.cpp b/host/Capture/DXGI.cpp index 2a781688..07ded009 100644 --- a/host/Capture/DXGI.cpp +++ b/host/Capture/DXGI.cpp @@ -304,6 +304,7 @@ GrabStatus DXGI::GrabFrame(FrameInfo & frame) frame.cursor.shape = m_pointer; frame.cursor.w = shapeInfo.Width; frame.cursor.h = shapeInfo.Height; + frame.cursor.pitch = shapeInfo.Pitch; frame.cursor.dataSize = m_pointerSize; } diff --git a/host/ICapture.h b/host/ICapture.h index 30753f06..817ca363 100644 --- a/host/ICapture.h +++ b/host/ICapture.h @@ -31,6 +31,7 @@ struct CursorInfo enum CursorType type; unsigned int w, h; + unsigned int pitch; void * shape; unsigned int dataSize; }; diff --git a/host/Service.cpp b/host/Service.cpp index 057357f8..b54f09a1 100644 --- a/host/Service.cpp +++ b/host/Service.cpp @@ -254,6 +254,7 @@ bool Service::Process() m_header->cursor.type = frame.cursor.type; m_header->cursor.w = frame.cursor.w; m_header->cursor.h = frame.cursor.h; + m_header->cursor.pitch = frame.cursor.pitch; if (frame.cursor.dataSize > KVMFR_CURSOR_BUFFER) { DEBUG_ERROR("Cursor shape size exceeds buffer size");