summaryrefslogtreecommitdiff
path: root/src/video/sdl_v.cpp
diff options
context:
space:
mode:
authorpeter1138 <peter1138@openttd.org>2010-01-04 02:32:36 +0000
committerpeter1138 <peter1138@openttd.org>2010-01-04 02:32:36 +0000
commitabb147d9742f349513d076a76b2957eb573d78e7 (patch)
tree57b0ff251d966e055785a8e289aacc6431540af4 /src/video/sdl_v.cpp
parent5ab64809fe72c38d373bdbed6ffa9b6660dd69d6 (diff)
downloadopenttd-abb147d9742f349513d076a76b2957eb573d78e7.tar.xz
(svn r18709) -Fix (r10227,FS#3464): Animation buffer for 32bpp-anim blitter was only validated during sprite blitting, other drawing operations didn't check it. Initial startup and window resize could therefore lead to crash.
Diffstat (limited to 'src/video/sdl_v.cpp')
-rw-r--r--src/video/sdl_v.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/video/sdl_v.cpp b/src/video/sdl_v.cpp
index 7c39bdba0..3168cf3e8 100644
--- a/src/video/sdl_v.cpp
+++ b/src/video/sdl_v.cpp
@@ -251,6 +251,9 @@ static bool CreateMainSurface(uint w, uint h)
_screen.pitch = newscreen->pitch / (bpp / 8);
_screen.dst_ptr = newscreen->pixels;
_sdl_screen = newscreen;
+
+ BlitterFactoryBase::GetCurrentBlitter()->PostResize();
+
InitPalette();
snprintf(caption, sizeof(caption), "OpenTTD %s", _openttd_revision);