mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-10-14 11:28:11 +00:00
[idd] implemented core shared memory functionallity and LGMP setup
This commit is contained in:
@@ -3,8 +3,17 @@
|
||||
#include <Windows.h>
|
||||
#include <wdf.h>
|
||||
#include <IddCx.h>
|
||||
|
||||
#include "CIVSHMEM.h"
|
||||
|
||||
extern "C" {
|
||||
#include "lgmp/host.h"
|
||||
}
|
||||
|
||||
#include "common/KVMFR.h"
|
||||
#define MAX_POINTER_SIZE (sizeof(KVMFRCursor) + (512 * 512 * 4))
|
||||
#define POINTER_SHAPE_BUFFERS 3
|
||||
|
||||
class CIndirectDeviceContext
|
||||
{
|
||||
private:
|
||||
@@ -12,11 +21,27 @@ private:
|
||||
IDDCX_ADAPTER m_adapter = nullptr;
|
||||
CIVSHMEM m_ivshmem;
|
||||
|
||||
PLGMPHost m_lgmp = nullptr;
|
||||
PLGMPHostQueue m_frameQueue = nullptr;
|
||||
|
||||
PLGMPHostQueue m_pointerQueue = nullptr;
|
||||
PLGMPMemory m_pointerMemory [LGMP_Q_POINTER_LEN ] = {};
|
||||
PLGMPMemory m_pointerShapeMemory[POINTER_SHAPE_BUFFERS] = {};
|
||||
|
||||
size_t m_maxFrameSize = 0;
|
||||
PLGMPMemory m_frameMemory[LGMP_Q_FRAME_LEN] = {};
|
||||
|
||||
bool SetupLGMP();
|
||||
|
||||
void LGMPTimer();
|
||||
|
||||
WDFTIMER m_lgmpTimer = nullptr;
|
||||
|
||||
public:
|
||||
CIndirectDeviceContext(_In_ WDFDEVICE wdfDevice) :
|
||||
m_wdfDevice(wdfDevice) {};
|
||||
|
||||
virtual ~CIndirectDeviceContext() {};
|
||||
virtual ~CIndirectDeviceContext();
|
||||
|
||||
void InitAdapter();
|
||||
|
||||
|
Reference in New Issue
Block a user