[host] initial service framework implemented

This commit is contained in:
Geoffrey McRae
2017-10-31 23:21:05 +11:00
parent 941f0f1c16
commit 3dd205bafc
10 changed files with 274 additions and 8 deletions

35
host/Service.h Normal file
View File

@@ -0,0 +1,35 @@
#pragma once
#define W32_LEAN_AND_MEAN
#include <Windows.h>
#include <stdbool.h>
#include "ivshmem.h"
#include "ICapture.h"
class Service
{
public:
static Service * Get()
{
if (!m_instance)
m_instance = new Service();
return m_instance;
}
bool Initialize();
void DeInitialize();
bool Process(HANDLE stopEvent);
private:
static Service * m_instance;
Service();
~Service();
bool m_initialized;
IVSHMEM * m_ivshmem;
HANDLE m_readyEvent;
ICapture * m_capture;
void * m_memory;
};