summaryrefslogtreecommitdiff
path: root/src/dyetool
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-02-13 21:12:32 +0300
committerAndrei Karas <akaras@inbox.ru>2014-02-13 21:12:32 +0300
commite0bea9ae2681668da02870719fd2ec48678a15f3 (patch)
tree7c875632d71d91f14f4d731deebaa8c9d284d94d /src/dyetool
parente405cb8b0520b87c5b1472c92e3d67d60f2b070f (diff)
downloadmv-e0bea9ae2681668da02870719fd2ec48678a15f3.tar.gz
mv-e0bea9ae2681668da02870719fd2ec48678a15f3.tar.bz2
mv-e0bea9ae2681668da02870719fd2ec48678a15f3.tar.xz
mv-e0bea9ae2681668da02870719fd2ec48678a15f3.zip
In dyecmd before saving images, convert it into default 32 bit format.
Diffstat (limited to 'src/dyetool')
-rw-r--r--src/dyetool/dyemain.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/dyetool/dyemain.cpp b/src/dyetool/dyemain.cpp
index c11cdd162..0699ce1ff 100644
--- a/src/dyetool/dyemain.cpp
+++ b/src/dyetool/dyemain.cpp
@@ -95,6 +95,9 @@ int main(int argc, char **argv)
printf("Error loading image\n");
return 1;
}
- ImageWriter::writePNG(image->getSDLSurface(), dst);
+ SDL_Surface *const surface = imageHelper->convertTo32Bit(
+ image->getSDLSurface());
+ ImageWriter::writePNG(surface, dst);
+ SDL_FreeSurface(surface);
return 0;
}