Commit 16c86d0d authored by Manish Singh's avatar Manish Singh Committed by Manish Singh
Browse files

Only store compression types we can actually handle in the save options

2005-04-25  Manish Singh  <yosh@gimp.org>

        * plug-in/common/tiff.c: Only store compression types we can actually
        handle in the save options parasite. Fixes bug #301557.
parent 2556233e
2005-04-25 Manish Singh <yosh@gimp.org>
* plug-in/common/tiff.c: Only store compression types we can actually
handle in the save options parasite. Fixes bug #301557.
2005-04-24 Sven Neumann <sven@gimp.org>
* app/base/temp-buf.c (generate_unique_tmp_filename): removed the
......
......@@ -700,7 +700,22 @@ load_image (const gchar *filename)
if (!TIFFGetField (tif, TIFFTAG_COMPRESSION, &tmp))
save_vals.compression = COMPRESSION_NONE;
else
save_vals.compression = tmp;
{
switch (tmp)
{
case COMPRESSION_NONE:
case COMPRESSION_LZW:
case COMPRESSION_PACKBITS:
case COMPRESSION_DEFLATE:
case COMPRESSION_JPEG:
save_vals.compression = tmp;
break;
default:
save_vals.compression = COMPRESSION_NONE;
break;
}
}
parasite = gimp_parasite_new ("tiff-save-options", 0,
sizeof (save_vals), &save_vals);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment