r16651 by jghali - #9829 : map grayscale to K channel when exporting grayscale image to 'Printer' target with color management enabled

scribus-commit scribus-commit at lists.scribus.net
Fri Jun 10 23:00:40 UTC 2011


Author: jghali
Date: Fri Jun 10 23:00:40 2011
New Revision: 16651

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=16651
Log:
#9829 : map grayscale to K channel when exporting grayscale image to 'Printer' target with color management enabled

Modified:
    trunk/Scribus/scribus/scimage.cpp

Modified: trunk/Scribus/scribus/scimage.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=16651&path=/trunk/Scribus/scribus/scimage.cpp
==============================================================================
--- trunk/Scribus/scribus/scimage.cpp (original)
+++ trunk/Scribus/scribus/scimage.cpp Fri Jun 10 23:00:40 2011
@@ -2101,21 +2101,20 @@
 					inputProfIsEmbedded = false;
 				}
 			}
+			else if (bilevel && (reqType == CMYKData))
+				inputProf = NULL; // Workaround to map directly gray to K channel
+			else if (ScCore->InputProfiles.contains(cmSettings.profileName()) && (cmSettings.profileName() != cmSettings.doc()->cmsSettings().DefaultImageRGBProfile))
+			{
+				imgInfo.profileName = cmSettings.profileName();
+				profilePath = ScCore->InputProfiles[imgInfo.profileName];
+				inputProfIsEmbedded = true;
+				inputProf = cmSettings.doc()->colorEngine.openProfileFromFile(profilePath);
+			}
 			else
 			{
-				if (ScCore->InputProfiles.contains(cmSettings.profileName()) && (cmSettings.profileName() != cmSettings.doc()->cmsSettings().DefaultImageRGBProfile))
-				{
-					imgInfo.profileName = cmSettings.profileName();
-					profilePath = ScCore->InputProfiles[imgInfo.profileName];
-					inputProfIsEmbedded = true;
-					inputProf = cmSettings.doc()->colorEngine.openProfileFromFile(profilePath);
-				}
-				else
-				{
-					inputProf = cmSettings.doc()->DocInputImageRGBProf;
-					imgInfo.profileName = cmSettings.doc()->cmsSettings().DefaultImageRGBProfile;
-					inputProfIsEmbedded = false;
-				}
+				inputProf = cmSettings.doc()->DocInputImageRGBProf;
+				imgInfo.profileName = cmSettings.doc()->cmsSettings().DefaultImageRGBProfile;
+				inputProfIsEmbedded = false;
 			}
 		}
 	}




More information about the scribus-commit mailing list