mirror of
https://gitlab.gnome.org/GNOME/gimp
synced 2024-10-20 19:43:01 +00:00
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.
This commit is contained in:
parent
2556233e5a
commit
16c86d0dbd
|
@ -1,3 +1,8 @@
|
||||||
|
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>
|
2005-04-24 Sven Neumann <sven@gimp.org>
|
||||||
|
|
||||||
* app/base/temp-buf.c (generate_unique_tmp_filename): removed the
|
* 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))
|
if (!TIFFGetField (tif, TIFFTAG_COMPRESSION, &tmp))
|
||||||
save_vals.compression = COMPRESSION_NONE;
|
save_vals.compression = COMPRESSION_NONE;
|
||||||
else
|
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,
|
parasite = gimp_parasite_new ("tiff-save-options", 0,
|
||||||
sizeof (save_vals), &save_vals);
|
sizeof (save_vals), &save_vals);
|
||||||
|
|
Loading…
Reference in a new issue