(svn r27775) -Fix [FS#6510]: Insufficient thread synchronisation when switching blitters. (JGR)

This commit is contained in:
frosch
2017-03-11 13:05:54 +00:00
parent d5f82bf55b
commit b1fe837b8e
6 changed files with 47 additions and 5 deletions

View File

@@ -817,11 +817,18 @@ bool VideoDriver_SDL::ToggleFullscreen(bool fullscreen)
}
bool VideoDriver_SDL::AfterBlitterChange()
{
return CreateMainSurface(_screen.width, _screen.height);
}
void VideoDriver_SDL::AcquireBlitterLock()
{
if (_draw_mutex != NULL) _draw_mutex->BeginCritical(true);
bool ret = CreateMainSurface(_screen.width, _screen.height);
}
void VideoDriver_SDL::ReleaseBlitterLock()
{
if (_draw_mutex != NULL) _draw_mutex->EndCritical(true);
return ret;
}
#endif /* WITH_SDL */