mirror of
https://github.com/narzoul/DDrawCompat
synced 2024-12-30 08:55:36 +01:00
Fixed issues with making the update thread persistent
Earlier the update thread was made persistent accross multiple primary surfaces, but some parts were not correctly updated. The update event handle was still being closed on release of the primary surface, and the update thread still exited if there was no primary surface immediately after it received an update event.
This commit is contained in:
parent
63b3112a58
commit
db02afefa9
@ -117,9 +117,6 @@ namespace
|
||||
g_paletteConverterSurface = nullptr;
|
||||
}
|
||||
|
||||
CloseHandle(g_updateEvent);
|
||||
g_updateEvent = nullptr;
|
||||
|
||||
ZeroMemory(&RealPrimarySurface::s_surfaceDesc, sizeof(RealPrimarySurface::s_surfaceDesc));
|
||||
|
||||
Compat::LogLeave("RealPrimarySurface::onRelease");
|
||||
@ -147,10 +144,6 @@ namespace
|
||||
while (true)
|
||||
{
|
||||
WaitForSingleObject(g_updateEvent, INFINITE);
|
||||
if (!g_frontBuffer)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
Compat::origProcs.AcquireDDThreadLock();
|
||||
ResetEvent(g_updateEvent);
|
||||
|
Loading…
x
Reference in New Issue
Block a user