fixed (reactivated) global animations (toons) for SDL 1.2 target
[rocksndiamonds.git] / src / libgame / sdl.h
index 79827b4501dc6247076dc4dd1385378d813ca1be..3a00cb1136a5ea745960b8d776dc97b68b85e77d 100644 (file)
 #if defined(PLATFORM_ANDROID)
 #define WINDOW_SCALING_STATUS  WINDOW_SCALING_NOT_AVAILABLE
 #define FULLSCREEN_STATUS      FULLSCREEN_AVAILABLE
-#define USE_DESKTOP_FULLSCREEN TRUE
 #elif defined(TARGET_SDL2)
 #define WINDOW_SCALING_STATUS  WINDOW_SCALING_AVAILABLE
 #define FULLSCREEN_STATUS      FULLSCREEN_AVAILABLE
-#define USE_DESKTOP_FULLSCREEN TRUE
 #else  // SDL 1.2
 #define WINDOW_SCALING_STATUS  WINDOW_SCALING_NOT_AVAILABLE
 #define FULLSCREEN_STATUS      FULLSCREEN_AVAILABLE
 #endif
 
+#if defined(TARGET_SDL2)
+#define USE_FINAL_SCREEN_BITMAP        FALSE
+#else
+#define USE_FINAL_SCREEN_BITMAP        TRUE
+#endif
+
 #define CURSOR_MAX_WIDTH       32
 #define CURSOR_MAX_HEIGHT      32
 
@@ -102,6 +106,10 @@ struct SDLSurfaceInfo
   int width, height;
   SDL_Surface *surface;
   SDL_Surface *surface_masked;
+#if defined(TARGET_SDL2)
+  SDL_Texture *texture;
+  SDL_Texture *texture_masked;
+#endif
 };
 
 struct MouseCursorInfo
@@ -428,6 +436,8 @@ struct MouseCursorInfo
 
 boolean SDLSetNativeSurface(SDL_Surface **);
 SDL_Surface *SDLGetNativeSurface(SDL_Surface *);
+void SDLCreateBitmapTextures(Bitmap *);
+void SDLFreeBitmapTextures(Bitmap *);
 
 #if defined(TARGET_SDL2)
 SDL_Surface *SDL_DisplayFormat(SDL_Surface *);
@@ -446,6 +456,7 @@ boolean SDLSetVideoMode(DrawBuffer **, boolean);
 void SDLCreateBitmapContent(Bitmap *, int, int, int);
 void SDLFreeBitmapPointers(Bitmap *);
 void SDLCopyArea(Bitmap *, Bitmap *, int, int, int, int, int, int, int);
+void SDLBlitTexture(Bitmap *, int, int, int, int, int, int, int);
 void SDLFillRectangle(Bitmap *, int, int, int, int, Uint32);
 void SDLFadeRectangle(Bitmap *, int, int, int, int, int, int, int,
                      void (*draw_border_function)(void));