gimp r28268 - in trunk: . app/core



Author: tobiasmue
Date: Mon Apr 13 20:14:49 2009
New Revision: 28268
URL: http://svn.gnome.org/viewvc/gimp?rev=28268&view=rev

Log:
Remove the ICC profile when image will be converted from/to grayscale mode.


Modified:
   trunk/ChangeLog
   trunk/app/core/gimpimage-convert.c

Modified: trunk/app/core/gimpimage-convert.c
==============================================================================
--- trunk/app/core/gimpimage-convert.c	(original)
+++ trunk/app/core/gimpimage-convert.c	Mon Apr 13 20:14:49 2009
@@ -1062,6 +1062,21 @@
       break;
     }
 
+  /* TODO: attach or remove the ICC profile */
+  switch (new_type)
+    {
+    case GIMP_RGB:
+    case GIMP_INDEXED:
+      if (old_type == GIMP_GRAY)
+        gimp_image_parasite_detach (image, "icc-profile");
+      break;
+    case GIMP_GRAY:
+      gimp_image_parasite_detach (image, "icc-profile");
+      break;
+    default:
+      break;
+    }
+
   /*  Delete the quantizer object, if there is one */
   if (quantobj)
     quantobj->delete_func (quantobj);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]