diff gfxconv.c @ 607:360b1ad83ed9

Rename things; Fix build by combining the conflicting rules.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 12 Apr 2013 11:21:37 +0300
parents d400e32b62d9
children
line wrap: on
line diff
--- a/gfxconv.c	Fri Apr 12 11:18:45 2013 +0300
+++ b/gfxconv.c	Fri Apr 12 11:21:37 2013 +0300
@@ -1099,6 +1099,7 @@
                 if (info) dmMsg(2, "%d bitplanes, %s interleave.\n", spec->nplanes, spec->interleave ? "with" : "without");
                 return dmWriteRAWImage(filename, image, spec);
             }
+            break;
 
         default:
             return DMERR_INVALID_DATA;
@@ -1441,6 +1442,15 @@
         
         dmImageFree(outImage);
     }
+    else
+    if (optOutFormat == FFMT_BITMAP)
+    {
+        if (optSequential)
+        {
+            dmError("Sequential output not supported for spr/char -> bitmap conversion.\n");
+            goto error;
+        }
+    }
 
     dmFree(bufData);
     return 0;
@@ -1618,6 +1628,11 @@
                         res = dmWriteBitmap(optOutFilename, &cimage, optOutSubFormat, TRUE);
                         break;
 
+                    case FFMT_CHAR:
+                    case FFMT_SPRITE:
+                        res = dmWriteSpritesAndChars(optOutFilename, outImage, optOutFormat, optInMulticolor);
+                        break;
+
                     default:
                         dmError("Unsupported output format for bitmap/image conversion.\n");
                         break;