mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-09-23 23:00:42 +00:00
Display driver loop refactor
This commit is contained in:
@@ -1,22 +1,17 @@
|
||||
#include "HostSuspendHook.h"
|
||||
#include "HostSuspendCallArgument.h"
|
||||
#include "HostSuspendCallArgument.h"
|
||||
|
||||
#include "DisplayDeviceManager.h"
|
||||
|
||||
#include "PLDrivers.h"
|
||||
#include "IGpDisplayDriver.h"
|
||||
|
||||
namespace
|
||||
{
|
||||
static PortabilityLayer::HostSuspendHook_t gs_suspendHook;
|
||||
static void *gs_suspendContext;
|
||||
}
|
||||
|
||||
namespace PortabilityLayer
|
||||
{
|
||||
void InstallHostSuspendHook(HostSuspendHook_t hook, void *context)
|
||||
void RenderFrames(unsigned int ticks)
|
||||
{
|
||||
gs_suspendHook = hook;
|
||||
gs_suspendContext = context;
|
||||
}
|
||||
|
||||
void SuspendApplication(HostSuspendCallID callID, const HostSuspendCallArgument *args, HostSuspendCallArgument *returnValue)
|
||||
{
|
||||
gs_suspendHook(gs_suspendContext, callID, args, returnValue);
|
||||
PLDrivers::GetDisplayDriver()->ServeTicks(ticks);
|
||||
DisplayDeviceManager::GetInstance()->IncrementTickCount(ticks);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user