changed using same (little endian) pixel format everywhere
[rocksndiamonds.git] / src / files.c
index e8de1142ecf24f958da1c2b548b342472b0102c5..5e95fb80f0cd908e4aeaa08800cd14b2c7738dd3 100644 (file)
@@ -13489,7 +13489,7 @@ void CreateCollectElementImages(void)
                  SDL_MapRGB(dst_bitmap->surface->format, 0x00, 0x00, 0x00));
 
   dst_bitmap->surface =
-    SDL_ConvertSurfaceFormat(dst_bitmap->surface, SDL_PIXELFORMAT_RGBA32, 0);
+    SDL_ConvertSurfaceFormat(dst_bitmap->surface, SDL_PIXELFORMAT_ARGB8888, 0);
 
   for (i = 0; i < MAX_NUM_ELEMENTS; i++)
   {
@@ -13516,7 +13516,7 @@ void CreateCollectElementImages(void)
                    SDL_MapRGB(tmp_bitmap->surface->format, 0x00, 0x00, 0x00));
 
     tmp_bitmap->surface =
-      SDL_ConvertSurfaceFormat(tmp_bitmap->surface, SDL_PIXELFORMAT_RGBA32, 0);
+      SDL_ConvertSurfaceFormat(tmp_bitmap->surface, SDL_PIXELFORMAT_ARGB8888, 0);
 
     tmp_bitmap->surface_masked = tmp_bitmap->surface;
 
@@ -13559,7 +13559,9 @@ void CreateCollectElementImages(void)
 
   Info("Converting image file from BMP to PNG ...");
 
-  system(cmd_convert);
+  if (system(cmd_convert) != 0)
+    Fail("converting image file failed");
+
   unlink(filename_bmp);
 
   Info("Done.");