mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-10-10 17:38:10 +00:00
[idd] initial indirect driver with Looking Glass monitor
This commit is contained in:
35
idd/LGIdd/CIndirectDeviceContext.h
Normal file
35
idd/LGIdd/CIndirectDeviceContext.h
Normal file
@@ -0,0 +1,35 @@
|
||||
#pragma once
|
||||
|
||||
#include <Windows.h>
|
||||
#include <wdf.h>
|
||||
#include <IddCx.h>
|
||||
|
||||
class CIndirectDeviceContext
|
||||
{
|
||||
private:
|
||||
WDFDEVICE m_wdfDevice;
|
||||
IDDCX_ADAPTER m_adapter = nullptr;
|
||||
|
||||
public:
|
||||
CIndirectDeviceContext(_In_ WDFDEVICE wdfDevice) :
|
||||
m_wdfDevice(wdfDevice) {};
|
||||
|
||||
virtual ~CIndirectDeviceContext() {};
|
||||
|
||||
void InitAdapter();
|
||||
|
||||
void FinishInit(UINT connectorIndex);
|
||||
};
|
||||
|
||||
struct CIndirectDeviceContextWrapper
|
||||
{
|
||||
CIndirectDeviceContext* context;
|
||||
|
||||
void Cleanup()
|
||||
{
|
||||
delete context;
|
||||
context = nullptr;
|
||||
}
|
||||
};
|
||||
|
||||
WDF_DECLARE_CONTEXT_TYPE(CIndirectDeviceContextWrapper);
|
Reference in New Issue
Block a user