rnd-20001125-2-src
[rocksndiamonds.git] / src / system.c
index d0c948a64dd360e59e43c94351715e845144e8d7..c600152f46636180f9964c4fa0f9798f6ff7ee79 100644 (file)
@@ -69,6 +69,15 @@ inline Bitmap CreateBitmap(int width, int height, int depth)
 #endif
 }
 
+inline void FreeBitmap(Bitmap bitmap)
+{
+#ifdef USE_SDL_LIBRARY
+  SDL_FreeSurface(bitmap);
+#else
+  XFreePixmap(display, bitmap);
+#endif
+}
+
 inline void ClearRectangle(Bitmap bitmap, int x, int y, int width, int height)
 {
 #ifdef USE_SDL_LIBRARY
@@ -241,7 +250,7 @@ inline Key GetEventKey(KeyEvent *event, boolean with_modifiers)
 inline boolean SetVideoMode(void)
 {
 #ifdef USE_SDL_LIBRARY
-  return SDLSetVideoMode(&backbuffer, &window);
+  return SDLSetVideoMode(&backbuffer);
 #else
   boolean success = TRUE;