diff options
author | Eugene Sandulenko | 2016-11-13 16:36:18 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2016-11-13 16:36:43 +0100 |
commit | 43438fbe1365115f1a4df1a452d14677fca3c86b (patch) | |
tree | 586473b75e63f5c50f34b07c8957a60795d351ba /backends/graphics | |
parent | a22e3bceac828177e720abc72773424e8a29bc72 (diff) | |
download | scummvm-rg350-43438fbe1365115f1a4df1a452d14677fca3c86b.tar.gz scummvm-rg350-43438fbe1365115f1a4df1a452d14677fca3c86b.tar.bz2 scummvm-rg350-43438fbe1365115f1a4df1a452d14677fca3c86b.zip |
CHEWY: Plug memory leaks
Diffstat (limited to 'backends/graphics')
-rw-r--r-- | backends/graphics/surfacesdl/surfacesdl-graphics.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp index 21e334d242..6cd5a47e1c 100644 --- a/backends/graphics/surfacesdl/surfacesdl-graphics.cpp +++ b/backends/graphics/surfacesdl/surfacesdl-graphics.cpp @@ -345,7 +345,7 @@ OSystem::TransactionError SurfaceSdlGraphicsManager::endGFXTransaction() { #if SDL_VERSION_ATLEAST(2, 0, 0) } else if (_videoMode.filtering != _oldVideoMode.filtering) { errors |= OSystem::kTransactionFilteringFailed; - + _videoMode.filtering = _oldVideoMode.filtering; #endif #ifdef USE_RGB_COLOR @@ -2350,7 +2350,7 @@ bool SurfaceSdlGraphicsManager::handleScalerHotkeys(Common::KeyCode key) { internUpdateScreen(); return true; } - + #if SDL_VERSION_ATLEAST(2, 0, 0) // Ctrl-Alt-f toggles filtering if (key == 'f') { @@ -2595,7 +2595,7 @@ void SurfaceSdlGraphicsManager::recreateScreenTexture() { return; SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, _videoMode.filtering ? "linear" : "nearest"); - + SDL_Texture *oldTexture = _screenTexture; _screenTexture = SDL_CreateTexture(_renderer, SDL_PIXELFORMAT_RGB565, SDL_TEXTUREACCESS_STREAMING, _videoMode.hardwareWidth, _videoMode.hardwareHeight); if (_screenTexture) @@ -2627,7 +2627,7 @@ SDL_Surface *SurfaceSdlGraphicsManager::SDL_SetVideoMode(int width, int height, SDL_GetWindowSize(_window->getSDLWindow(), &_windowWidth, &_windowHeight); setWindowResolution(_windowWidth, _windowHeight); - + SDL_SetHint(SDL_HINT_RENDER_SCALE_QUALITY, _videoMode.filtering ? "linear" : "nearest"); _screenTexture = SDL_CreateTexture(_renderer, SDL_PIXELFORMAT_RGB565, SDL_TEXTUREACCESS_STREAMING, width, height); |