From cbfa598446f656e5082f96458ee9540f1a58d180 Mon Sep 17 00:00:00 2001 From: Thierry Crozat Date: Sun, 23 Oct 2016 20:04:05 +0100 Subject: OPENGL: Remove hack to avoid issues with OSD messages from other threads --- backends/graphics/opengl/opengl-graphics.cpp | 6 ------ backends/graphics/opengl/opengl-graphics.h | 8 -------- 2 files changed, 14 deletions(-) (limited to 'backends/graphics') diff --git a/backends/graphics/opengl/opengl-graphics.cpp b/backends/graphics/opengl/opengl-graphics.cpp index a0882347b5..7b41699e80 100644 --- a/backends/graphics/opengl/opengl-graphics.cpp +++ b/backends/graphics/opengl/opengl-graphics.cpp @@ -377,7 +377,6 @@ void OpenGLGraphicsManager::updateScreen() { #ifdef USE_OSD { - Common::StackLock lock(_osdMutex); if (_osdMessageChangeRequest) { osdMessageUpdateSurface(); } @@ -741,11 +740,6 @@ void OpenGLGraphicsManager::setCursorPalette(const byte *colors, uint start, uin void OpenGLGraphicsManager::displayMessageOnOSD(const char *msg) { #ifdef USE_OSD - // HACK: Actually no client code should use graphics functions from - // another thread. But the MT-32 emulator and network synchronization still do, - // thus we need to make sure this doesn't happen while a updateScreen call is done. - Common::StackLock lock(_osdMutex); - _osdMessageChangeRequest = true; _osdMessageNextData = msg; diff --git a/backends/graphics/opengl/opengl-graphics.h b/backends/graphics/opengl/opengl-graphics.h index 01672f4f5c..d3f8d792ba 100644 --- a/backends/graphics/opengl/opengl-graphics.h +++ b/backends/graphics/opengl/opengl-graphics.h @@ -596,14 +596,6 @@ private: kOSDIconTopMargin = 10, kOSDIconRightMargin = 10 }; - - /** - * Mutex for the OSD draw calls. - * - * Mutex to allow displayMessageOnOSD and displayActivityIconOnOSD - * to be used from the audio and network threads. - */ - Common::Mutex _osdMutex; #endif }; -- cgit v1.2.3