diff options
author | Philipp Lohmann <pl@openoffice.org> | 2008-01-10 14:39:13 +0000 |
---|---|---|
committer | Philipp Lohmann <pl@openoffice.org> | 2008-01-10 14:39:13 +0000 |
commit | 23d4ebbdcb5a0952132040bbd8f928083789210a (patch) | |
tree | e5cf2a1bc78fc4a0b3c0cd828359c7e71798ed98 /icc | |
parent | 9c4f6472dd4b1642ff3ce20ec1ae0430f850c660 (diff) |
#i81093# sRGB profile
Diffstat (limited to 'icc')
-rw-r--r-- | icc/README | 27 | ||||
-rw-r--r-- | icc/SampleICC-1.3.2.patch | 2385 | ||||
-rw-r--r-- | icc/makefile.mk | 68 | ||||
-rw-r--r-- | icc/prj/build.lst | 3 | ||||
-rw-r--r-- | icc/prj/d.lst | 5 | ||||
-rw-r--r-- | icc/source/create_sRGB_profile/create_sRGB_profile.cpp | 237 |
6 files changed, 2612 insertions, 113 deletions
diff --git a/icc/README b/icc/README new file mode 100644 index 000000000000..9812ab9fd85d --- /dev/null +++ b/icc/README @@ -0,0 +1,27 @@ +Date: 2007-12-10 + +This project is used to generate the ICC color +profile needed in module vcl in order to export +to PDF/A-1a. +It's composed of a small application, which lurks in: + +icc/source/create_sRGB_profile + +That application links to a support library +(icc/download/SampleICC-1.3.2), build at OOo +build time. +Finally, the application is run at OOo build time to +generate the only file delivered to solver: +sRGB-IEC61966-2.1.hxx. + +If you need to change the data into the ICC profile, +please change the create_sRGB_profile. + +The library was downloaded from: +http://sampleicc.sourceforge.net +on 2007-08-23. + +For information on ICC profiles, you may want to visit: +http://www.color.org + +beppec56@openoffice.org diff --git a/icc/SampleICC-1.3.2.patch b/icc/SampleICC-1.3.2.patch new file mode 100644 index 000000000000..9f0e3edce51e --- /dev/null +++ b/icc/SampleICC-1.3.2.patch @@ -0,0 +1,2385 @@ +--- SampleICC-1.3.2/IccProfLib/icProfileHeader.h 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/icProfileHeader.h 2008-01-10 13:49:26.389626916 +0100 +@@ -659,10 +659,11 @@ + typedef enum { + icFlare0 = 0x00000000, /* 0% flare */ + icFlare100 = 0x00000001, /* 100% flare */ ++ icMaxEnumFlare = 0xFFFFFFFF + } icMeasurementFlare; + + /** Convenience Enum Definition - Not defined in ICC specification*/ +-#define icMaxEnumFlare ((icMeasurementFlare) 0xFFFFFFFF) ++/*#define icMaxEnumFlare ((icMeasurementFlare) 0xFFFFFFFF)*/ + #define icMaxFlare ((icMeasurementFlare) 0xFFFFFFFF) /* as defined by earlier versions */ + + +--- SampleICC-1.3.2/Contrib/ICC_utils/Stubs.h.oosrc 2007-09-13 16:57:28.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/Contrib/ICC_utils/Stubs.h 2007-09-13 16:58:14.000000000 +0200 +@@ -130,7 +130,7 @@ + + // use one of these to force desired sort order in assoc. containers of DPX + bool +- DPX::operator<(const DPX& p) const ++ operator<(const DPX& p) const + { + return (r_ != p.r_) ? (r_ < p.r_) : ((g_ != p.g_) ? (g_ < p.g_) : (b_ < p.b_)); + } +--- SampleICC-1.3.2/IccProfLib/IccTagBasic.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccTagBasic.cpp 2007-09-13 17:44:16.000000000 +0200 +@@ -166,7 +166,7 @@ + CIccInfo Info; + sReport += icValidateNonCompliantMsg; + sReport += Info.GetSigName(sig); +- sReport += " - Reserved Value must be zero.\r\n"; ++ sReport += " - Reserved Value must be zero.\n"; + + rv = icValidateNonCompliant; + } +@@ -340,7 +340,7 @@ + sprintf(buf, "%u Bytes.", m_nSize-4); + sDescription += buf; + +- sDescription += "\r\n\r\nData Follows:\r\n"; ++ sDescription += "\n\nData Follows:\n"; + + icMemDump(sDescription, m_pData+4, m_nSize-4); + } +@@ -511,7 +511,7 @@ + if (m_szText && *m_szText) + sDescription += m_szText; + +- sDescription += "\"\r\n"; ++ sDescription += "\"\n"; + } + + +@@ -629,14 +629,14 @@ + if (m_nBufSize<7) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Tag must have at least seven text characters.\r\n"; ++ sReport += " - Tag must have at least seven text characters.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + break; + default: + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Unknown Tag.\r\n"; ++ sReport += " - Unknown Tag.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + int i; +@@ -644,14 +644,14 @@ + if (m_szText[i]&0x80) { + sReport += icValidateWarning; + sReport += sSigName; +- sReport += " - Text do not contain 7bit data.\r\n"; ++ sReport += " - Text do not contain 7bit data.\n"; + } + } + } + else { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Empty Tag.\r\n"; ++ sReport += " - Empty Tag.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + +@@ -941,7 +941,7 @@ + if (m_szText && *m_szText) + sDescription += m_szText; + +- sDescription += "\"\r\n"; ++ sDescription += "\"\n"; + } + + +@@ -1101,7 +1101,7 @@ + if (m_nScriptSize>67) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - ScriptCode count must not be greater than 67.\r\n"; ++ sReport += " - ScriptCode count must not be greater than 67.\n"; + + rv =icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1260,7 +1260,7 @@ + CIccInfo Fmt; + + sDescription += Fmt.GetSigName(m_nSig); +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -1320,7 +1320,7 @@ + { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sprintf(buf, " - %s: Unknown Technology.\r\n", Info.GetSigName(m_nSig)); ++ sprintf(buf, " - %s: Unknown Technology.\n", Info.GetSigName(m_nSig)); + sReport += buf; + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1336,7 +1336,7 @@ + { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sprintf(buf, " - %s: Unknown Reference Medium Gamut.\r\n", Info.GetSigName(m_nSig)); ++ sprintf(buf, " - %s: Unknown Reference Medium Gamut.\n", Info.GetSigName(m_nSig)); + sReport += buf; + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1355,7 +1355,7 @@ + { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sprintf(buf, " - %s: Unknown Colorimetric Intent Image State.\r\n", Info.GetSigName(m_nSig)); ++ sprintf(buf, " - %s: Unknown Colorimetric Intent Image State.\n", Info.GetSigName(m_nSig)); + sReport += buf; + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1686,7 +1686,7 @@ + + sDescription.reserve(sDescription.size() + m_nSize*79); + +- sprintf(buf, "BEGIN_NAMED_COLORS flags=%08x %u %u\r\n", m_nVendorFlags, m_nSize, m_nDeviceCoords); ++ sprintf(buf, "BEGIN_NAMED_COLORS flags=%08x %u %u\n", m_nVendorFlags, m_nSize, m_nDeviceCoords); + sDescription += buf; + + for (i=0; i<m_nSize; i++) { +@@ -1717,7 +1717,7 @@ + sDescription += buf; + } + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + + pNamedColor = (SIccNamedColorEntry*)((icChar*)pNamedColor + m_nColorEntrySize); + } +@@ -2082,7 +2082,7 @@ + if (!m_nSize) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Empty tag!\r\n"; ++ sReport += " - Empty tag!\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + +@@ -2092,14 +2092,14 @@ + if (m_nDeviceCoords != nCoords) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Incorrect number of device co-ordinates.\r\n"; ++ sReport += " - Incorrect number of device co-ordinates.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + } + else { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + } +@@ -2285,7 +2285,7 @@ + icChar buf[128]; + + if (m_nSize == 1 ) { +- sprintf(buf, "X=%.4lf, Y=%.4lf, Z=%.4lf\r\n", icFtoD(m_XYZ[0].X), icFtoD(m_XYZ[0].Y), icFtoD(m_XYZ[0].Z)); ++ sprintf(buf, "X=%.4lf, Y=%.4lf, Z=%.4lf\n", icFtoD(m_XYZ[0].X), icFtoD(m_XYZ[0].Y), icFtoD(m_XYZ[0].Z)); + sDescription += buf; + } + else { +@@ -2293,7 +2293,7 @@ + sDescription.reserve(sDescription.size() + m_nSize*79); + + for (i=0; i<m_nSize; i++) { +- sprintf(buf, "value[%u]: X=%.4lf, Y=%.4lf, Z=%.4lf\r\n", i, icFtoD(m_XYZ[i].X), icFtoD(m_XYZ[i].Y), icFtoD(m_XYZ[i].Z)); ++ sprintf(buf, "value[%u]: X=%.4lf, Y=%.4lf, Z=%.4lf\n", i, icFtoD(m_XYZ[i].X), icFtoD(m_XYZ[i].Y), icFtoD(m_XYZ[i].Z)); + sDescription += buf; + } + } +@@ -2347,7 +2347,7 @@ + if (!m_nSize) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Empty tag.\r\n"; ++ sReport += " - Empty tag.\n"; + + rv = icMaxStatus(rv, icValidateWarning); + return rv; +@@ -2553,14 +2553,14 @@ + + icUInt32Number i; + //sDescription.reserve(sDescription.size() + m_nChannels*79); +- sprintf(buf, "Number of Channels : %u\r\n", m_nChannels); ++ sprintf(buf, "Number of Channels : %u\n", m_nChannels); + sDescription += buf; + +- sprintf(buf, "Colorant Encoding : %s\r\n", Fmt.GetColorantEncoding((icColorantEncoding)m_nColorantType)); ++ sprintf(buf, "Colorant Encoding : %s\n", Fmt.GetColorantEncoding((icColorantEncoding)m_nColorantType)); + sDescription += buf; + + for (i=0; i<m_nChannels; i++) { +- sprintf(buf, "value[%u]: x=%.3lf, y=%.3lf\r\n", i, icUFtoD(m_xy[i].x), icUFtoD(m_xy[i].y)); ++ sprintf(buf, "value[%u]: x=%.3lf, y=%.3lf\n", i, icUFtoD(m_xy[i].x), icUFtoD(m_xy[i].y)); + sDescription += buf; + } + +@@ -2617,7 +2617,7 @@ + if (m_nChannels!=3) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of device channels must be three.\r\n"; ++ sReport += " - Number of device channels must be three.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -2629,7 +2629,7 @@ + (m_xy[2].x != icDtoUF((icFloatNumber)0.150)) || (m_xy[2].y != icDtoUF((icFloatNumber)0.060)) ) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Chromaticity data does not match specification.\r\n"; ++ sReport += " - Chromaticity data does not match specification.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + break; +@@ -2642,7 +2642,7 @@ + (m_xy[2].x != icDtoUF((icFloatNumber)0.155)) || (m_xy[2].y != icDtoUF((icFloatNumber)0.070)) ) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Chromaticity data does not match specification.\r\n"; ++ sReport += " - Chromaticity data does not match specification.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + break; +@@ -2655,7 +2655,7 @@ + (m_xy[2].x != icDtoUF((icFloatNumber)0.15)) || (m_xy[2].y != icDtoUF((icFloatNumber)0.06)) ) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Chromaticity data does not match specification.\r\n"; ++ sReport += " - Chromaticity data does not match specification.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + break; +@@ -2668,7 +2668,7 @@ + (m_xy[2].x != icDtoUF((icFloatNumber)0.155)) || (m_xy[2].y != icDtoUF((icFloatNumber)0.070)) ) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Chromaticity data does not match specification.\r\n"; ++ sReport += " - Chromaticity data does not match specification.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + break; +@@ -2678,7 +2678,7 @@ + { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Invalid colorant type encoding.\r\n"; ++ sReport += " - Invalid colorant type encoding.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + } +@@ -2884,27 +2884,27 @@ + + if (m_nSize == 1 ) { + if (Tsig==icSigS15Fixed16ArrayType) +- sprintf(buf, "Value = %.4lf\r\n", icFtoD(m_Num[0])); ++ sprintf(buf, "Value = %.4lf\n", icFtoD(m_Num[0])); + else +- sprintf(buf, "Value = %.4lf\r\n", icUFtoD(m_Num[0])); ++ sprintf(buf, "Value = %.4lf\n", icUFtoD(m_Num[0])); + sDescription += buf; + } + else { + icUInt32Number i; + + if (Tsig==icSigS15Fixed16ArrayType && m_nSize==9) { +- sDescription += "Matrix Form:\r\n"; ++ sDescription += "Matrix Form:\n"; + icMatrixDump(sDescription, (icS15Fixed16Number*)m_Num); + +- sDescription += "\r\nArrayForm:\r\n"; ++ sDescription += "\nArrayForm:\n"; + } + sDescription.reserve(sDescription.size() + m_nSize*79); + + for (i=0; i<m_nSize; i++) { + if (Tsig==icSigS15Fixed16ArrayType) +- sprintf(buf, "Value[%u] = %.4lf\r\n", i, icFtoD(m_Num[i])); ++ sprintf(buf, "Value[%u] = %.4lf\n", i, icFtoD(m_Num[i])); + else +- sprintf(buf, "Value[%u] = %.4lf\r\n", i, icUFtoD(m_Num[i])); ++ sprintf(buf, "Value[%u] = %.4lf\n", i, icUFtoD(m_Num[i])); + sDescription += buf; + } + } +@@ -3172,7 +3172,7 @@ + icChar buf[128]; + + if (m_nSize == 1 ) { +- sprintf(buf, "Value = %u (0x%x)\r\n", m_Num[0], m_Num[0]); ++ sprintf(buf, "Value = %u (0x%x)\n", m_Num[0], m_Num[0]); + sDescription += buf; + } + else { +@@ -3180,7 +3180,7 @@ + sDescription.reserve(sDescription.size() + m_nSize*79); + + for (i=0; i<m_nSize; i++) { +- sprintf(buf, "Value[%u] = %u (0x%x)\r\n", i, m_Num[i], m_Num[i]); ++ sprintf(buf, "Value[%u] = %u (0x%x)\n", i, m_Num[i], m_Num[i]); + sDescription += buf; + } + } +@@ -3374,15 +3374,15 @@ + CIccInfo Fmt; + icChar buf[128]; + +- sDescription += Fmt.GetStandardObserverName(m_Data.stdObserver); sDescription += "\r\n"; +- sprintf(buf, "Backing measurement: X=%.4lf, Y=%.4lf, Z=%.4lf\r\n", ++ sDescription += Fmt.GetStandardObserverName(m_Data.stdObserver); sDescription += "\n"; ++ sprintf(buf, "Backing measurement: X=%.4lf, Y=%.4lf, Z=%.4lf\n", + icFtoD(m_Data.backing.X), + icFtoD(m_Data.backing.Y), + icFtoD(m_Data.backing.Z)); + sDescription += buf; +- sDescription += Fmt.GetMeasurementGeometryName(m_Data.geometry); sDescription += "\r\n"; +- sDescription += Fmt.GetMeasurementFlareName(m_Data.flare); sDescription += "\r\n"; +- sDescription += Fmt.GetIlluminantName(m_Data.illuminant); sDescription += "\r\n"; ++ sDescription += Fmt.GetMeasurementGeometryName(m_Data.geometry); sDescription += "\n"; ++ sDescription += Fmt.GetMeasurementFlareName(m_Data.flare); sDescription += "\n"; ++ sDescription += Fmt.GetIlluminantName(m_Data.illuminant); sDescription += "\n"; + } + + +@@ -3416,7 +3416,7 @@ + default: + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Invalid standard observer encoding.\r\n"; ++ sReport += " - Invalid standard observer encoding.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -3429,7 +3429,7 @@ + default: + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Invalid measurement geometry encoding.\r\n"; ++ sReport += " - Invalid measurement geometry encoding.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -3448,7 +3448,7 @@ + default: + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Invalid standard illuminant encoding.\r\n"; ++ sReport += " - Invalid standard illuminant encoding.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -3902,9 +3902,9 @@ + + for (i=m_Strings->begin(); i!=m_Strings->end(); i++) { + if (i!=m_Strings->begin()) +- sDescription += "\r\n"; ++ sDescription += "\n"; + +- sprintf(szBuf, "Language = '%c%c', Region = '%c%c'\r\n", ++ sprintf(szBuf, "Language = '%c%c', Region = '%c%c'\n", + i->m_nLanguageCode>>8, i->m_nLanguageCode, + i->m_nCountryCode>>8, i->m_nCountryCode); + +@@ -3919,7 +3919,7 @@ + i->GetAnsi(szBuf, nSize); + sDescription += "\""; + sDescription += szBuf; +- sDescription += "\"\r\n"; ++ sDescription += "\"\n"; + } + } + +@@ -3948,7 +3948,7 @@ + if (!m_Strings->size()) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Empty tag!\r\n"; ++ sReport += " - Empty tag!\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + +@@ -4246,15 +4246,15 @@ + { + icChar buf[128]; + +- sDescription = "\r\nData:\r\n"; ++ sDescription = "\nData:\n"; + + if (IsTypeAscii()) { +- sprintf(buf, "%s\r\n", (icChar*)m_pData); ++ sprintf(buf, "%s\n", (icChar*)m_pData); + sDescription += buf; + } + else + for (int i = 0; i<(int)m_nSize; i++) { +- sprintf(buf, "%d\r\n", m_pData[i]); ++ sprintf(buf, "%d\n", m_pData[i]); + sDescription += buf; + } + +@@ -4312,7 +4312,7 @@ + default: + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Invalid data flag encoding.\r\n"; ++ sReport += " - Invalid data flag encoding.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -4477,11 +4477,11 @@ + icChar buf[128]; + + sDescription = "Date = "; +- sprintf(buf, "%u-%u-%u\r\n", m_DateTime.month, m_DateTime.day, m_DateTime.year); ++ sprintf(buf, "%u-%u-%u\n", m_DateTime.month, m_DateTime.day, m_DateTime.year); + sDescription += buf; + + sDescription += "Time = "; +- sprintf(buf, "%u:%u:%u\r\n", m_DateTime.hours, m_DateTime.minutes, m_DateTime.seconds); ++ sprintf(buf, "%u:%u:%u\n", m_DateTime.hours, m_DateTime.minutes, m_DateTime.seconds); + sDescription += buf; + } + +@@ -4697,12 +4697,12 @@ + { + icChar buf[128]; + +- sprintf(buf, "Colorant Count : %u\r\n", m_nCount); ++ sprintf(buf, "Colorant Count : %u\n", m_nCount); + sDescription += buf; +- sDescription += "Order of Colorants:\r\n"; ++ sDescription += "Order of Colorants:\n"; + + for (int i=0; i<(int)m_nCount; i++) { +- sprintf(buf, "%u\r\n", m_pData[i]); ++ sprintf(buf, "%u\n", m_pData[i]); + sDescription += buf; + } + } +@@ -4757,7 +4757,7 @@ + if (!pProfile) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateWarning); + return rv; + } +@@ -4765,7 +4765,7 @@ + if (m_nCount != icGetSpaceSamples(pProfile->m_Header.colorSpace)) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Incorrect number of colorants.\r\n"; ++ sReport += " - Incorrect number of colorants.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -4977,7 +4977,7 @@ + icUInt32Number i, nLen, nMaxLen=0; + icFloatNumber Lab[3]; + +- sprintf(buf, "BEGIN_COLORANTS %u\r\n", m_nCount); ++ sprintf(buf, "BEGIN_COLORANTS %u\n", m_nCount); + sDescription += buf; + + for (i=0; i<m_nCount; i++) { +@@ -4988,11 +4988,11 @@ + sDescription += "# NAME "; + + if (m_PCS == icSigXYZData) { +- sprintf(buf, "XYZ_X XYZ_Y XYZ_Z\r\n"); ++ sprintf(buf, "XYZ_X XYZ_Y XYZ_Z\n"); + sDescription += buf; + } + else { +- sprintf(buf, "Lab_L Lab_a Lab_b\r\n"); ++ sprintf(buf, "Lab_L Lab_a Lab_b\n"); + sDescription += buf; + } + for (i=0; i<m_nCount; i++) { +@@ -5003,7 +5003,7 @@ + sDescription += buf; + + if (m_PCS == icSigXYZData) { +- sprintf(buf, "%7.4lf %7.4lf %7.4lf\r\n", icUSFtoD(m_pData[i].data[0]), icUSFtoD(m_pData[i].data[1]), icUSFtoD(m_pData[i].data[2])); ++ sprintf(buf, "%7.4lf %7.4lf %7.4lf\n", icUSFtoD(m_pData[i].data[0]), icUSFtoD(m_pData[i].data[1]), icUSFtoD(m_pData[i].data[2])); + sDescription += buf; + } + else { +@@ -5011,7 +5011,7 @@ + Lab[1] = icU16toF(m_pData[i].data[1]); + Lab[2] = icU16toF(m_pData[i].data[2]); + icLabFromPcs(Lab); +- sprintf(buf, "%7.4lf %8.4lf %8.4lf\r\n", Lab[0], Lab[1], Lab[2]); ++ sprintf(buf, "%7.4lf %8.4lf %8.4lf\n", Lab[0], Lab[1], Lab[2]); + sDescription += buf; + } + } +@@ -5066,7 +5066,7 @@ + if (!pProfile) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateWarning); + return rv; + } +@@ -5076,7 +5076,7 @@ + if (pProfile->m_Header.deviceClass!=icSigLinkClass) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Use of this tag is allowed only in DeviceLink Profiles.\r\n"; ++ sReport += " - Use of this tag is allowed only in DeviceLink Profiles.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + } +@@ -5084,7 +5084,7 @@ + if (m_nCount != icGetSpaceSamples(pProfile->m_Header.colorSpace)) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Incorrect number of colorants.\r\n"; ++ sReport += " - Incorrect number of colorants.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -5261,13 +5261,13 @@ + icChar buf[128]; + CIccInfo Fmt; + +- sprintf(buf, "Illuminant Tristimulus values: X = %.4lf, Y = %.4lf, Z = %.4lf\r\n", ++ sprintf(buf, "Illuminant Tristimulus values: X = %.4lf, Y = %.4lf, Z = %.4lf\n", + icFtoD(m_XYZIllum.X), + icFtoD(m_XYZIllum.Y), + icFtoD(m_XYZIllum.Z)); + sDescription += buf; + +- sprintf(buf, "Surround Tristimulus values: X = %.4lf, Y = %.4lf, Z = %.4lf\r\n", ++ sprintf(buf, "Surround Tristimulus values: X = %.4lf, Y = %.4lf, Z = %.4lf\n", + icFtoD(m_XYZSurround.X), + icFtoD(m_XYZSurround.Y), + icFtoD(m_XYZSurround.Z)); +@@ -5276,7 +5276,7 @@ + sDescription += "Illuminant Type: "; + + sDescription += Fmt.GetIlluminantName(m_illumType); +- sDescription += "\r\n"; ++ sDescription += "\n"; + + } + +@@ -5800,32 +5800,32 @@ + icChar buf[128], buf2[28]; + icUInt32Number count=0; + +- sprintf(buf, "Number of Profile Description Structures: %u\r\n", m_Descriptions->size()); ++ sprintf(buf, "Number of Profile Description Structures: %u\n", m_Descriptions->size()); + sDescription += buf; + + for (i=m_Descriptions->begin(); i!=m_Descriptions->end(); i++, count++) { +- sDescription += "\r\n"; ++ sDescription += "\n"; + +- sprintf(buf, "Profile Description Structure Number [%u] follows:\r\n", count+1); ++ sprintf(buf, "Profile Description Structure Number [%u] follows:\n", count+1); + sDescription += buf; + +- sprintf(buf, "Device Manufacturer Signature: %s\r\n", icGetSig(buf2, i->m_deviceMfg, false)); ++ sprintf(buf, "Device Manufacturer Signature: %s\n", icGetSig(buf2, i->m_deviceMfg, false)); + sDescription += buf; + +- sprintf(buf, "Device Model Signature: %s\r\n", icGetSig(buf2, i->m_deviceModel, false)); ++ sprintf(buf, "Device Model Signature: %s\n", icGetSig(buf2, i->m_deviceModel, false)); + sDescription += buf; + +- sprintf(buf, "Device Attributes: %08x%08x\r\n", (icUInt32Number)(i->m_attributes >> 32), (icUInt32Number)(i->m_attributes)); ++ sprintf(buf, "Device Attributes: %08x%08x\n", (icUInt32Number)(i->m_attributes >> 32), (icUInt32Number)(i->m_attributes)); + sDescription += buf; + +- sprintf(buf, "Device Technology Signature: %s\r\n", icGetSig(buf2, i->m_technology, false)); ++ sprintf(buf, "Device Technology Signature: %s\n", icGetSig(buf2, i->m_technology, false)); + sDescription += buf; + +- sprintf(buf, "Description of device manufacturer: \r\n"); ++ sprintf(buf, "Description of device manufacturer: \n"); + sDescription += buf; + i->m_deviceMfgDesc.Describe(sDescription); + +- sprintf(buf, "Description of device model: \r\n"); ++ sprintf(buf, "Description of device model: \n"); + sDescription += buf; + i->m_deviceModelDesc.Describe(sDescription); + } +@@ -5886,7 +5886,7 @@ + { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sprintf(buf, " - %s: Unknown Technology.\r\n", Info.GetSigName(i->m_technology)); ++ sprintf(buf, " - %s: Unknown Technology.\n", Info.GetSigName(i->m_technology)); + sReport += buf; + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -5896,7 +5896,7 @@ + sReport += icValidateNonCompliantMsg; + sReport += sSigName; + +- sReport += " Contains non-aligned deviceMfgDesc text tag information\r\n"; ++ sReport += " Contains non-aligned deviceMfgDesc text tag information\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -5905,7 +5905,7 @@ + sReport += icValidateNonCompliantMsg; + sReport += sSigName; + +- sReport += " Contains non-aligned deviceModelDesc text tag information\r\n"; ++ sReport += " Contains non-aligned deviceModelDesc text tag information\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -6174,25 +6174,25 @@ + CIccResponse16List::iterator j; + + sDescription += "Measurement Unit: "; +- sDescription += Fmt.GetMeasurementUnit((icSignature)GetMeasurementType()); sDescription += "\r\n"; ++ sDescription += Fmt.GetMeasurementUnit((icSignature)GetMeasurementType()); sDescription += "\n"; + + + for (int i=0; i<m_nChannels; i++) { + nResponseList = m_Response16ListArray[i]; + +- sDescription += "\r\n"; +- sprintf(buf, "Maximum Colorant XYZ Measurement for Channel-%u : X=%.4lf, Y=%.4lf, Z=%.4lf\r\n", i+1, ++ sDescription += "\n"; ++ sprintf(buf, "Maximum Colorant XYZ Measurement for Channel-%u : X=%.4lf, Y=%.4lf, Z=%.4lf\n", i+1, + icFtoD(m_maxColorantXYZ[i].X), icFtoD(m_maxColorantXYZ[i].Y), icFtoD(m_maxColorantXYZ[i].Z)); + sDescription += buf; + +- sprintf(buf, "Number of Measurements for Channel-%u : %u\r\n", i+1, nResponseList.size()); ++ sprintf(buf, "Number of Measurements for Channel-%u : %u\n", i+1, nResponseList.size()); + sDescription += buf; + +- sprintf(buf, "Measurement Data for Channel-%u follows:\r\n", i+1); ++ sprintf(buf, "Measurement Data for Channel-%u follows:\n", i+1); + sDescription += buf; + + for (j=nResponseList.begin(); j!=nResponseList.end(); j++) { +- sprintf(buf, "Device Value= %u : Measurement Value= %.4lf\r\n", j->deviceCode, icFtoD(j->measurementValue)); ++ sprintf(buf, "Device Value= %u : Measurement Value= %.4lf\n", j->deviceCode, icFtoD(j->measurementValue)); + sDescription += buf; + } + } +@@ -6234,14 +6234,14 @@ + default: + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Unknown measurement unit signature.\r\n"; ++ sReport += " - Unknown measurement unit signature.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + + if (!m_nChannels) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Incorrect number of channels.\r\n"; ++ sReport += " - Incorrect number of channels.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + return rv; + } +@@ -6479,17 +6479,17 @@ + CIccResponseCurveSet::iterator i; + icChar buf[128]; + +- sprintf(buf, "Number of Channels: %u\r\n", m_nChannels); ++ sprintf(buf, "Number of Channels: %u\n", m_nChannels); + sDescription += buf; + +- sprintf(buf, "Number of Measurement Types used: %u\r\n", m_ResponseCurves->size()); ++ sprintf(buf, "Number of Measurement Types used: %u\n", m_ResponseCurves->size()); + sDescription += buf; + + int count = 0; + for (i=m_ResponseCurves->begin(); i!=m_ResponseCurves->end(); i++, count++) { +- sDescription += "\r\n"; ++ sDescription += "\n"; + +- sprintf(buf, "Response Curve for measurement type [%u] follows:\r\n", count+1); ++ sprintf(buf, "Response Curve for measurement type [%u] follows:\n", count+1); + sDescription += buf; + + i->Describe(sDescription); +@@ -6658,7 +6658,7 @@ + if (!pProfile) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateWarning); + return rv; + } +@@ -6666,13 +6666,13 @@ + if (m_nChannels!=icGetSpaceSamples(pProfile->m_Header.colorSpace)) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Incorrect number of channels.\r\n"; ++ sReport += " - Incorrect number of channels.\n"; + } + + if (!GetNumResponseCurveTypes()) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Empty Tag!.\r\n"; ++ sReport += " - Empty Tag!.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + else { +--- SampleICC-1.3.2/IccProfLib/IccMpeACS.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccMpeACS.cpp 2007-09-13 17:40:28.000000000 +0200 +@@ -136,17 +136,17 @@ + icChar sigBuf[30]; + + if (GetBAcsSig()) +- sDescription += "ELEM_bACS\r\n"; ++ sDescription += "ELEM_bACS\n"; + else +- sDescription += "ELEM_eACS\r\n"; ++ sDescription += "ELEM_eACS\n"; + + icGetSig(sigBuf, m_signature); + sDescription += " Signature = "; + sDescription += sigBuf; +- sDescription += "\r\n"; ++ sDescription += "\n"; + + if (m_pData) { +- sDescription += "\r\nData Follows:\r\n"; ++ sDescription += "\nData Follows:\n"; + + icMemDump(sDescription, m_pData, m_nDataSize); + } +--- SampleICC-1.3.2/IccProfLib/IccTagMPE.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccTagMPE.cpp 2007-09-13 17:46:00.000000000 +0200 +@@ -218,7 +218,7 @@ + icGetSig(sigbuf, m_sig), m_nSize); + sDescription += buf; + +- sDescription += "\r\n\r\nData Follows:\r\n"; ++ sDescription += "\n\nData Follows:\n"; + + icMemDump(sDescription, m_pData, m_nSize); + +@@ -364,7 +364,7 @@ + sReport += " - Contains unknown processing element type ("; + icGetSig(buf, m_sig, true); + sReport += buf; +- sReport += ").\r\n"; ++ sReport += ").\n"; + + return icValidateCriticalError; + } +@@ -392,7 +392,7 @@ + sReport += " - Element "; + sSigName = Info.GetSigName(GetType()); + sReport += sSigName; +- sReport += " - Reserved Value must be zero.\r\n"; ++ sReport += " - Reserved Value must be zero.\n"; + + rv = icValidateNonCompliant; + } +@@ -738,18 +738,18 @@ + { + icChar buf[128]; + +- sprintf(buf, "BEGIN MULTI_PROCESS_ELEMENT_TAG %d %d\r\n", m_nInputChannels, m_nOutputChannels); ++ sprintf(buf, "BEGIN MULTI_PROCESS_ELEMENT_TAG %d %d\n", m_nInputChannels, m_nOutputChannels); + sDescription += buf; +- sDescription += "\r\n"; ++ sDescription += "\n"; + + CIccMultiProcessElementList::iterator i; + int j; + + for (j=0, i=m_list->begin(); i!=m_list->end(); j++, i++) { +- sprintf(buf, "PROCESS_ELEMENT #%d\r\n", j+1); ++ sprintf(buf, "PROCESS_ELEMENT #%d\n", j+1); + sDescription += buf; + i->ptr->Describe(sDescription); +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + } + +@@ -1207,13 +1207,13 @@ + if (m_nInputChannels != m_nOutputChannels) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " No processing elements and input and output channels do not match!\r\n"; ++ sReport += " No processing elements and input and output channels do not match!\n"; + return icValidateCriticalError; + } + else { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " No processing elements.\r\n"; ++ sReport += " No processing elements.\n"; + return icValidateWarning; + } + } +@@ -1224,7 +1224,7 @@ + if (i->ptr->NumInputChannels() != m_nInputChannels) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " Mis-matching number of input channels!\r\n"; ++ sReport += " Mis-matching number of input channels!\n"; + return icValidateCriticalError; + } + +@@ -1239,7 +1239,7 @@ + sReport += "->"; + sReport += i->ptr->GetClassName(); + +- sReport += " Mis-matching number of channels!\r\n"; ++ sReport += " Mis-matching number of channels!\n"; + return icValidateCriticalError; + } + } +@@ -1251,7 +1251,7 @@ + if (last && last->NumOutputChannels() != m_nOutputChannels) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " Mis-matching number of output channels!\r\n"; ++ sReport += " Mis-matching number of output channels!\n"; + return icValidateCriticalError; + } + +--- SampleICC-1.3.2/IccProfLib/IccTagLut.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccTagLut.cpp 2007-09-13 17:45:28.000000000 +0200 +@@ -323,23 +323,23 @@ + icChar buf[128], *ptr; + + if (!m_nSize) { +- sprintf(buf, "BEGIN_CURVE In_Out\r\n"); ++ sprintf(buf, "BEGIN_CURVE In_Out\n"); + sDescription += buf; +- sDescription += "Y = X\r\n"; ++ sDescription += "Y = X\n"; + } + else if (m_nSize==1) { + icFloatNumber dGamma = (icFloatNumber)(m_Curve[0] * 256.0); +- sprintf(buf, "BEGIN_CURVE In_Out\r\n"); ++ sprintf(buf, "BEGIN_CURVE In_Out\n"); + sDescription += buf; +- sprintf(buf, "Y = X ^ %.4lf\r\n", dGamma); ++ sprintf(buf, "Y = X ^ %.4lf\n", dGamma); + sDescription += buf; + } + else { + int i; + +- sprintf(buf, "BEGIN_LUT In_Out 1 1\r\n"); ++ sprintf(buf, "BEGIN_LUT In_Out 1 1\n"); + sDescription += buf; +- sDescription += "IN OUT\r\n"; ++ sDescription += "IN OUT\n"; + + for (i=0; i<(int)m_nSize; i++) { + ptr = buf; +@@ -354,12 +354,12 @@ + + ptr += strlen(ptr); + +- strcpy(ptr, "\r\n"); ++ strcpy(ptr, "\n"); + + sDescription += buf; + } + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -383,23 +383,23 @@ + icChar buf[128], *ptr; + + if (!m_nSize) { +- sprintf(buf, "BEGIN_CURVE %s\r\n", szName); ++ sprintf(buf, "BEGIN_CURVE %s\n", szName); + sDescription += buf; +- sDescription += "Y = X\r\n"; ++ sDescription += "Y = X\n"; + } + else if (m_nSize==1) { + icFloatNumber dGamma = (icFloatNumber)(m_Curve[0] * 256.0); +- sprintf(buf, "BEGIN_CURVE %s\r\n", szName); ++ sprintf(buf, "BEGIN_CURVE %s\n", szName); + sDescription += buf; +- sprintf(buf, "Y = X ^ %.4lf\r\n", dGamma); ++ sprintf(buf, "Y = X ^ %.4lf\n", dGamma); + sDescription += buf; + } + else { + int i; + +- sprintf(buf, "BEGIN_LUT %s 1 1\r\n", szName); ++ sprintf(buf, "BEGIN_LUT %s 1 1\n", szName); + sDescription += buf; +- sDescription += "IN OUT\r\n"; ++ sDescription += "IN OUT\n"; + + sDescription.reserve(sDescription.size() + m_nSize * 20); + +@@ -416,12 +416,12 @@ + + ptr += strlen(ptr); + +- strcpy(ptr, "\r\n"); ++ strcpy(ptr, "\n"); + + sDescription += buf; + } + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -614,7 +614,7 @@ + if (m_Curve[0]>0.0 || m_Curve[m_nSize-1]<1.0) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Curve cannot be accurately inverted.\r\n"; ++ sReport += " - Curve cannot be accurately inverted.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + } +@@ -822,67 +822,67 @@ + { + icChar buf[128]; + +- sprintf(buf, "FunctionType: %04Xh\r\n", m_nFunctionType); ++ sprintf(buf, "FunctionType: %04Xh\n", m_nFunctionType); + sDescription += buf; + + switch(m_nFunctionType) { + case 0x0000: +- sprintf(buf, "Y = X ^ %.4lf\r\n", icFtoD(m_Param[0])); ++ sprintf(buf, "Y = X ^ %.4lf\n", icFtoD(m_Param[0])); + sDescription += buf; + return; + + case 0x0001: +- sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf when (X >= %.4lf / %.4lf)\r\n", ++ sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf when (X >= %.4lf / %.4lf)\n", + icFtoD(m_Param[1]), icFtoD(m_Param[2]), icFtoD(m_Param[0]), + -icFtoD(m_Param[2]), icFtoD(m_Param[1])); + sDescription += buf; + +- sprintf(buf, "Y = 0 when (X < %.4lf / %.4lf)\r\n", ++ sprintf(buf, "Y = 0 when (X < %.4lf / %.4lf)\n", + -icFtoD(m_Param[2]), icFtoD(m_Param[1])); + sDescription += buf; + return; + + case 0x0002: +- sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf + %.4lf when (X >= %.4lf / %.4lf)\r\n", ++ sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf + %.4lf when (X >= %.4lf / %.4lf)\n", + icFtoD(m_Param[1]), icFtoD(m_Param[2]), icFtoD(m_Param[0]), + icFtoD(m_Param[3]), + -icFtoD(m_Param[2]), icFtoD(m_Param[1])); + sDescription += buf; + +- sprintf(buf, "Y = %.4lf when (X < %.4lf / %.4lf)\r\n", icFtoD(m_Param[3]), ++ sprintf(buf, "Y = %.4lf when (X < %.4lf / %.4lf)\n", icFtoD(m_Param[3]), + -icFtoD(m_Param[2]), icFtoD(m_Param[1])); + sDescription += buf; + return; + + case 0x0003: +- sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf when (X >= %.4lf)\r\n", ++ sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf when (X >= %.4lf)\n", + icFtoD(m_Param[1]), icFtoD(m_Param[2]), icFtoD(m_Param[0]), + icFtoD(m_Param[4])); + sDescription += buf; + +- sprintf(buf, "Y = %lf * X when (X < %.4lf)\r\n", ++ sprintf(buf, "Y = %lf * X when (X < %.4lf)\n", + icFtoD(m_Param[3]), icFtoD(m_Param[4])); + sDescription += buf; + return; + + case 0x0004: +- sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf + %.4lf when (X >= %.4lf)\r\n", ++ sprintf(buf, "Y = (%.4lf * X + %.4lf) ^ %.4lf + %.4lf when (X >= %.4lf)\n", + icFtoD(m_Param[1]), icFtoD(m_Param[2]), icFtoD(m_Param[0]), + icFtoD(m_Param[5]), icFtoD(m_Param[4])); + sDescription += buf; + +- sprintf(buf, "Y = %lf * X + %.4lf when (X < %.4lf)\r\n", ++ sprintf(buf, "Y = %lf * X + %.4lf when (X < %.4lf)\n", + icFtoD(m_Param[3]), icFtoD(m_Param[6]), icFtoD(m_Param[4])); + sDescription += buf; + return; + + default: + int i; +- sprintf(buf, "Unknown Function with %d parameters:\r\n"); ++ sprintf(buf, "Unknown Function with %d parameters:\n"); + sDescription += buf; + + for (i=0; i<m_nNumParam; i++) { +- sprintf(buf, "Param[%d] = %.4lf\r\n", i, icFtoD(m_Param[i])); ++ sprintf(buf, "Param[%d] = %.4lf\n", i, icFtoD(m_Param[i])); + sDescription += buf; + } + } +@@ -907,10 +907,10 @@ + { + icChar buf[128]; + +- sprintf(buf, "BEGIN_CURVE %s\r\n", szName); ++ sprintf(buf, "BEGIN_CURVE %s\n", szName); + sDescription += buf; + Describe(sDescription); +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -1106,7 +1106,7 @@ + if (m_nReserved2!=0) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Reserved Value must be zero.\r\n"; ++ sReport += " - Reserved Value must be zero.\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1116,7 +1116,7 @@ + if (m_nNumParam!=1) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of parameters inconsistent with function type.\r\n"; ++ sReport += " - Number of parameters inconsistent with function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1125,7 +1125,7 @@ + if (m_nNumParam!=3) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of parameters inconsistent with function type.\r\n"; ++ sReport += " - Number of parameters inconsistent with function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1134,7 +1134,7 @@ + if (m_nNumParam!=4) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of parameters inconsistent with function type.\r\n"; ++ sReport += " - Number of parameters inconsistent with function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1143,7 +1143,7 @@ + if (m_nNumParam!=5) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of parameters inconsistent with function type.\r\n"; ++ sReport += " - Number of parameters inconsistent with function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1152,7 +1152,7 @@ + if (m_nNumParam!=7) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Number of parameters inconsistent with function type.\r\n"; ++ sReport += " - Number of parameters inconsistent with function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1160,7 +1160,7 @@ + default: + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Unknown function type.\r\n"; ++ sReport += " - Unknown function type.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -1170,7 +1170,7 @@ + if (lval>0.0 || uval<1.0) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Curve cannot be accurately inverted.\r\n"; ++ sReport += " - Curve cannot be accurately inverted.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + } +@@ -1255,32 +1255,32 @@ + { + icChar buf[128]; + +- sprintf(buf, "BEGIN_MATRIX %s\r\n", szName); ++ sprintf(buf, "BEGIN_MATRIX %s\n", szName); + sDescription += buf; + + if (!m_bUseConstants) { +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", + m_e[0], m_e[1], m_e[2]); + sDescription += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", + m_e[3], m_e[4], m_e[5]); + sDescription += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", + m_e[6], m_e[7], m_e[8]); + sDescription += buf; + } + else { +- sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\n", + m_e[0], m_e[1], m_e[2], m_e[9]); + sDescription += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\n", + m_e[3], m_e[4], m_e[5], m_e[10]); + sDescription += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\r\n", ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf + %8.4lf\n", + m_e[6], m_e[7], m_e[8], m_e[11]); + sDescription += buf; + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + /** +@@ -1377,7 +1377,7 @@ + if (m_e[0]!=1.0 || m_e[4]!=1.0 || m_e[9]!=1.0 || sum!=3.0) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Matrix must be identity.\r\n"; ++ sReport += " - Matrix must be identity.\n"; + rv = icValidateNonCompliant; + } + } +@@ -1754,7 +1754,7 @@ + + ptr += sprintf(ptr, " %s", m_pVal); + } +- strcpy(ptr, "\r\n"); ++ strcpy(ptr, "\n"); + sDescription += (const icChar*)m_pOutText; + + } +@@ -1866,7 +1866,7 @@ + icChar szOutText[2048], szColor[40]; + int i, len; + +- sprintf(szOutText, "BEGIN_LUT %s %d %d\r\n", szName, m_nInput, m_nOutput); ++ sprintf(szOutText, "BEGIN_LUT %s %d %d\n", szName, m_nInput, m_nOutput); + sDescription += szOutText; + + for (i=0; i<m_nInput; i++) { +@@ -1883,7 +1883,7 @@ + sDescription += szOutText; + } + +- sDescription += "\r\n"; ++ sDescription += "\n"; + + len = 0; + for (i=0; i<m_nInput; i++) { +@@ -1907,7 +1907,7 @@ + + Iterate(sDescription, 0, 0); + +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -2693,7 +2693,7 @@ + if (m_nReserved2[0]!=0 || m_nReserved2[1]!=0 || m_nReserved2[2]!=0) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - Reserved Value must be zero.\r\n"; ++ sReport += " - Reserved Value must be zero.\n"; + + rv = icValidateNonCompliant; + } +@@ -2704,7 +2704,7 @@ + if (m_GridPoints[i]<2) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sprintf(temp, " - CLUT: At least 2 grid points should be present in dimension %u.\r\n",i ); ++ sprintf(temp, " - CLUT: At least 2 grid points should be present in dimension %u.\n",i ); + sReport += temp; + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -3122,7 +3122,7 @@ + if (!pProfile) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateWarning); + return rv; + } +@@ -3138,7 +3138,7 @@ + if (m_nInput!=nInput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of input channels.\r\n"; ++ sReport += " - Incorrect number of input channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3146,7 +3146,7 @@ + if (m_nOutput!=nOutput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of output channels.\r\n"; ++ sReport += " - Incorrect number of output channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3160,7 +3160,7 @@ + if (m_nInput!=nInput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of input channels.\r\n"; ++ sReport += " - Incorrect number of input channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3168,7 +3168,7 @@ + if (m_nOutput!=nOutput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of output channels.\r\n"; ++ sReport += " - Incorrect number of output channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3180,7 +3180,7 @@ + if (m_nInput!=nInput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of input channels.\r\n"; ++ sReport += " - Incorrect number of input channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3188,7 +3188,7 @@ + if (m_nOutput!=nOutput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of output channels.\r\n"; ++ sReport += " - Incorrect number of output channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3206,7 +3206,7 @@ + if (!m_CLUT) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - CLUT must be present.\r\n"; ++ sReport += " - CLUT must be present.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3748,7 +3748,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of B-curves.\r\n"; ++ sReport += " - Incorrect number of B-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3762,7 +3762,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of M-curves.\r\n"; ++ sReport += " - Incorrect number of M-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3772,7 +3772,7 @@ + if (!m_CLUT) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - CLUT must be present if using A-curves.\r\n"; ++ sReport += " - CLUT must be present if using A-curves.\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -3784,7 +3784,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of A-curves.\r\n"; ++ sReport += " - Incorrect number of A-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3876,7 +3876,7 @@ + if (!pProfile) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Tag validation incomplete: Pointer to profile unavailable.\r\n"; ++ sReport += " - Tag validation incomplete: Pointer to profile unavailable.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + return rv; + } +@@ -3900,7 +3900,7 @@ + if (m_nOutput!=nOutput) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of output channels.\r\n"; ++ sReport += " - Incorrect number of output channels.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -3913,7 +3913,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of B-curves.\r\n"; ++ sReport += " - Incorrect number of B-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3927,7 +3927,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of M-curves.\r\n"; ++ sReport += " - Incorrect number of M-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -3937,7 +3937,7 @@ + if (!m_CLUT) { + sReport += icValidateNonCompliantMsg; + sReport += sSigName; +- sReport += " - CLUT must be present if using A-curves.\r\n"; ++ sReport += " - CLUT must be present if using A-curves.\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -3949,7 +3949,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of A-curves.\r\n"; ++ sReport += " - Incorrect number of A-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4311,7 +4311,7 @@ + if (pTagCurve->GetSize()==1) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - lut8Tags do not support single entry gamma curves.\r\n"; ++ sReport += " - lut8Tags do not support single entry gamma curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4319,7 +4319,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of B-curves.\r\n"; ++ sReport += " - Incorrect number of B-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4336,7 +4336,7 @@ + if (m_XYZMatrix[0]!=1.0 || m_XYZMatrix[4]!=1.0 || m_XYZMatrix[9]!=1.0 || sum!=3.0) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Matrix must be identity.\r\n"; ++ sReport += " - Matrix must be identity.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + } +@@ -4351,7 +4351,7 @@ + if (pTagCurve->GetSize()==1) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - lut8Tags do not support single entry gamma curves.\r\n"; ++ sReport += " - lut8Tags do not support single entry gamma curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4359,7 +4359,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of A-curves.\r\n"; ++ sReport += " - Incorrect number of A-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4721,7 +4721,7 @@ + if (pTagCurve->GetSize()==1) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - lut16Tags do not support single entry gamma curves.\r\n"; ++ sReport += " - lut16Tags do not support single entry gamma curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4729,7 +4729,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of B-curves.\r\n"; ++ sReport += " - Incorrect number of B-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4746,7 +4746,7 @@ + if (m_XYZMatrix[0]!=1.0 || m_XYZMatrix[4]!=1.0 || m_XYZMatrix[9]!=1.0 || sum!=3.0) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " - Matrix must be identity.\r\n"; ++ sReport += " - Matrix must be identity.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + } +@@ -4761,7 +4761,7 @@ + if (pTagCurve->GetSize()==1) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - lut16Tags do not support single entry gamma curves.\r\n"; ++ sReport += " - lut16Tags do not support single entry gamma curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -4769,7 +4769,7 @@ + else { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " - Incorrect number of A-curves.\r\n"; ++ sReport += " - Incorrect number of A-curves.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +--- SampleICC-1.3.2/IccProfLib/IccProfile.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccProfile.cpp 2007-09-13 17:42:41.000000000 +0200 +@@ -567,7 +567,7 @@ + + if (!ReadBasic(pIO)) { + sReport += icValidateCriticalErrorMsg; +- sReport += " - Unable to read profile!**\r\n\tProfile has invalid structure!\r\n"; ++ sReport += " - Unable to read profile!**\n\tProfile has invalid structure!\n"; + Cleanup(); + + return icValidateCriticalError; +@@ -576,7 +576,7 @@ + // Check profile header + if (!CheckFileSize(pIO)) { + sReport += icValidateNonCompliantMsg; +- sReport += "Bad Header File Size\r\n"; ++ sReport += "Bad Header File Size\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -588,7 +588,7 @@ + CalcProfileID(pIO, &profileID); + if (strncmp((char*)profileID.ID8, (char*)m_Header.profileID.ID8, 16) != 0) { + sReport += icValidateNonCompliantMsg; +- sReport += "Bad Profile ID\r\n"; ++ sReport += "Bad Profile ID\n"; + + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -601,7 +601,7 @@ + sReport += icValidateCriticalErrorMsg; + sReport += " - "; + sReport += Info.GetTagSigName(i->TagInfo.sig); +- sReport += " - Tag has invalid structure!\r\n"; ++ sReport += " - Tag has invalid structure!\n"; + + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -1026,14 +1026,14 @@ + + default: + sReport += icValidateCriticalErrorMsg; +- sprintf(buf, " - %s: Unknown profile class!\r\n", Info.GetProfileClassSigName(m_Header.deviceClass)); ++ sprintf(buf, " - %s: Unknown profile class!\n", Info.GetProfileClassSigName(m_Header.deviceClass)); + sReport += buf; + rv = icMaxStatus(rv, icValidateCriticalError); + } + + if (!Info.IsValidSpace(m_Header.colorSpace)) { + sReport += icValidateCriticalErrorMsg; +- sprintf(buf, " - %s: Unknown color space!\r\n", Info.GetColorSpaceSigName(m_Header.colorSpace)); ++ sprintf(buf, " - %s: Unknown color space!\n", Info.GetColorSpaceSigName(m_Header.colorSpace)); + sReport += buf; + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -1041,7 +1041,7 @@ + if (m_Header.deviceClass==icSigLinkClass) { + if (!Info.IsValidSpace(m_Header.pcs)) { + sReport += icValidateCriticalErrorMsg; +- sprintf(buf, " - %s: Unknown pcs color space!\r\n", Info.GetColorSpaceSigName(m_Header.pcs)); ++ sprintf(buf, " - %s: Unknown pcs color space!\n", Info.GetColorSpaceSigName(m_Header.pcs)); + sReport += buf; + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -1049,7 +1049,7 @@ + else { + if (m_Header.pcs!=icSigXYZData && m_Header.pcs!=icSigLabData) { + sReport += icValidateCriticalErrorMsg; +- sprintf(buf, " - %s: Invalid pcs color space!\r\n", Info.GetColorSpaceSigName(m_Header.pcs)); ++ sprintf(buf, " - %s: Invalid pcs color space!\n", Info.GetColorSpaceSigName(m_Header.pcs)); + sReport += buf; + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -1068,7 +1068,7 @@ + + default: + sReport += icValidateWarningMsg; +- sprintf(buf, " - %s: Unknown platform signature.\r\n", Info.GetPlatformSigName(m_Header.platform)); ++ sprintf(buf, " - %s: Unknown platform signature.\n", Info.GetPlatformSigName(m_Header.platform)); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1095,7 +1095,7 @@ + + default: + sReport += icValidateWarningMsg; +- sprintf(buf, " - %s: Unregisterd CMM signature.\r\n", Info.GetCmmSigName((icCmmSignature)m_Header.cmmId)); ++ sprintf(buf, " - %s: Unregisterd CMM signature.\n", Info.GetCmmSigName((icCmmSignature)m_Header.cmmId)); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1109,7 +1109,7 @@ + + default: + sReport += icValidateCriticalErrorMsg; +- sprintf(buf, " - %s: Unknown rendering intent!\r\n", Info.GetRenderingIntentName((icRenderingIntent)m_Header.renderingIntent)); ++ sprintf(buf, " - %s: Unknown rendering intent!\n", Info.GetRenderingIntentName((icRenderingIntent)m_Header.renderingIntent)); + sReport += buf; + rv = icMaxStatus(rv, icValidateCriticalError); + } +@@ -1120,7 +1120,7 @@ + icFloatNumber Z = icFtoD(m_Header.illuminant.Z); + if (X<0.9640 || X>0.9644 || Y!=1.0 || Z<0.8247 || Z>0.8251) { + sReport += icValidateNonCompliantMsg; +- sReport += " - Non D50 Illuminant XYZ values.\r\n"; ++ sReport += " - Non D50 Illuminant XYZ values.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1130,7 +1130,7 @@ + } + if (sum) { + sReport += icValidateNonCompliantMsg; +- sReport += " - Reserved value must be zero.\r\n"; ++ sReport += " - Reserved value must be zero.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1163,7 +1163,7 @@ + { + sReport += icValidateWarningMsg; + sReport += buf; +- sReport += " - Tag exclusion test failed.\r\n"; ++ sReport += " - Tag exclusion test failed.\n"; + rv = false; + } + } +@@ -1177,7 +1177,7 @@ + { + sReport += icValidateWarningMsg; + sReport += buf; +- sReport += " - Tag exclusion test failed.\r\n"; ++ sReport += " - Tag exclusion test failed.\n"; + rv = false; + } + break; +@@ -1192,7 +1192,7 @@ + { + sReport += icValidateWarningMsg; + sReport += buf; +- sReport += " - Tag exclusion test failed.\r\n"; ++ sReport += " - Tag exclusion test failed.\n"; + rv = false; + } + break; +@@ -1234,7 +1234,7 @@ + if (!IsTypeValid(tagsig, typesig)) { + sReport += icValidateNonCompliantMsg; + sReport += buf; +- sprintf(buf," - %s: Invalid tag type (Might be critical!).\r\n", Info.GetTagTypeSigName(typesig)); ++ sprintf(buf," - %s: Invalid tag type (Might be critical!).\n", Info.GetTagTypeSigName(typesig)); + sReport += buf; + rv = icMaxStatus(rv, icValidateNonCompliant); + } +@@ -1477,7 +1477,7 @@ + { + if (m_Tags->size() <= 0) { + sReport += icValidateCriticalErrorMsg; +- sReport += "No tags present.\r\n"; ++ sReport += "No tags present.\n"; + return icValidateCriticalError; + } + +@@ -1486,7 +1486,7 @@ + if (!GetTag(icSigProfileDescriptionTag) || + !GetTag(icSigCopyrightTag)) { + sReport += icValidateNonCompliantMsg; +- sReport += "Required tags missing.\r\n"; ++ sReport += "Required tags missing.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1495,7 +1495,7 @@ + if (sig != icSigLinkClass) { + if (!GetTag(icSigMediaWhitePointTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Media white point tag missing.\r\n"; ++ sReport += "Media white point tag missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1505,7 +1505,7 @@ + if (m_Header.colorSpace == icSigGrayData) { + if (!GetTag(icSigGrayTRCTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Gray TRC tag missing.\r\n"; ++ sReport += "Gray TRC tag missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1515,7 +1515,7 @@ + !GetTag(icSigBlueMatrixColumnTag) || !GetTag(icSigRedTRCTag) || + !GetTag(icSigGreenTRCTag) || !GetTag(icSigBlueTRCTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1526,7 +1526,7 @@ + if (m_Header.colorSpace == icSigGrayData) { + if (!GetTag(icSigGrayTRCTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Gray TRC tag missing.\r\n"; ++ sReport += "Gray TRC tag missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1536,7 +1536,7 @@ + !GetTag(icSigBlueMatrixColumnTag) || !GetTag(icSigRedTRCTag) || + !GetTag(icSigGreenTRCTag) || !GetTag(icSigBlueTRCTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1547,7 +1547,7 @@ + if (m_Header.colorSpace == icSigGrayData) { + if (!GetTag(icSigGrayTRCTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Gray TRC tag missing.\r\n"; ++ sReport += "Gray TRC tag missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + } +@@ -1556,13 +1556,13 @@ + !GetTag(icSigAToB1Tag) || !GetTag(icSigBToA1Tag) || + !GetTag(icSigAToB2Tag) || !GetTag(icSigBToA2Tag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + + if (!GetTag(icSigGamutTag)) { + sReport += icValidateNonCompliantMsg; +- sReport += "Gamut tag missing.\r\n"; ++ sReport += "Gamut tag missing.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1585,7 +1585,7 @@ + case icSig16colorData: + if (!GetTag(icSigColorantTableTag)) { + sReport += icValidateNonCompliantMsg; +- sReport += "xCLR output profile is missing colorantTableTag\r\n"; ++ sReport += "xCLR output profile is missing colorantTableTag\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1599,14 +1599,14 @@ + case icSigLinkClass: + if (!GetTag(icSigAToB0Tag) || !GetTag(icSigProfileSequenceDescTag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + + if (icIsSpaceCLR(m_Header.colorSpace)) { + if (!GetTag(icSigColorantTableTag)) { + sReport += icValidateNonCompliantMsg; +- sReport += "Required tag(s) missing.\r\n"; ++ sReport += "Required tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + } +@@ -1614,7 +1614,7 @@ + if (icIsSpaceCLR(m_Header.pcs)) { + if (!GetTag(icSigColorantTableOutTag)) { + sReport += icValidateNonCompliantMsg; +- sReport += "Required tag(s) missing.\r\n"; ++ sReport += "Required tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + } +@@ -1623,7 +1623,7 @@ + case icSigColorSpaceClass: + if (!GetTag(icSigAToB0Tag) || !GetTag(icSigBToA0Tag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1631,7 +1631,7 @@ + case icSigAbstractClass: + if (!GetTag(icSigAToB0Tag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + break; +@@ -1639,7 +1639,7 @@ + case icSigNamedColorClass: + if (!GetTag(icSigNamedColor2Tag)) { + sReport += icValidateCriticalErrorMsg; +- sReport += "Critical tag(s) missing.\r\n"; ++ sReport += "Critical tag(s) missing.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + } + +@@ -1647,7 +1647,7 @@ + + default: + sReport += icValidateCriticalErrorMsg; +- sReport += "Unknown Profile Class.\r\n"; ++ sReport += "Unknown Profile Class.\n"; + rv = icMaxStatus(rv, icValidateCriticalError); + break; + } +@@ -1724,7 +1724,7 @@ + // Check for duplicate tags + if (!AreTagsUnique()) { + sReport += icValidateWarning; +- sReport += " - There are duplicate tags.\r\n"; ++ sReport += " - There are duplicate tags.\n"; + rv =icMaxStatus(rv, icValidateWarning); + } + +@@ -1979,7 +1979,7 @@ + sReport = icValidateCriticalErrorMsg; + sReport += " - "; + sReport += szFilename; +- sReport += "- Invalid Filename\r\n"; ++ sReport += "- Invalid Filename\n"; + delete pFileIO; + return NULL; + } +--- SampleICC-1.3.2/IccProfLib/IccUtil.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccUtil.cpp 2007-09-13 17:48:38.000000000 +0200 +@@ -678,11 +678,11 @@ + { + icChar buf[128]; + +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", icFtoD(pMatrix[0]), icFtoD(pMatrix[1]), icFtoD(pMatrix[2])); ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", icFtoD(pMatrix[0]), icFtoD(pMatrix[1]), icFtoD(pMatrix[2])); + sDump += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", icFtoD(pMatrix[3]), icFtoD(pMatrix[4]), icFtoD(pMatrix[5])); ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", icFtoD(pMatrix[3]), icFtoD(pMatrix[4]), icFtoD(pMatrix[5])); + sDump += buf; +- sprintf(buf, "%8.4lf %8.4lf %8.4lf\r\n", icFtoD(pMatrix[6]), icFtoD(pMatrix[7]), icFtoD(pMatrix[8])); ++ sprintf(buf, "%8.4lf %8.4lf %8.4lf\n", icFtoD(pMatrix[6]), icFtoD(pMatrix[7]), icFtoD(pMatrix[8])); + sDump += buf; + } + +@@ -1516,19 +1516,19 @@ + + if (XYZ.X < 0) { + sReport += icValidateNonCompliantMsg; +- sReport += " - XYZNumber: Negative X value!\r\n"; ++ sReport += " - XYZNumber: Negative X value!\n"; + rv = icValidateNonCompliant; + } + + if (XYZ.Y < 0) { + sReport += icValidateNonCompliantMsg; +- sReport += " - XYZNumber: Negative Y value!\r\n"; ++ sReport += " - XYZNumber: Negative Y value!\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + + if (XYZ.Z < 0) { + sReport += icValidateNonCompliantMsg; +- sReport += " - XYZNumber: Negative Z value!\r\n"; ++ sReport += " - XYZNumber: Negative Z value!\n"; + rv = icMaxStatus(rv, icValidateNonCompliant); + } + +@@ -1548,7 +1548,7 @@ + icChar buf[128]; + if (dateTime.year<1992) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid year!\r\n",dateTime.year); ++ sprintf(buf," - %u: Invalid year!\n",dateTime.year); + sReport += buf; + rv = icValidateWarning; + } +@@ -1557,7 +1557,7 @@ + if (newtime->tm_mon==11 && newtime->tm_mday==31) { + if (dateTime.year>(year+1)) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid year!\r\n",dateTime.year); ++ sprintf(buf," - %u: Invalid year!\n",dateTime.year); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1565,7 +1565,7 @@ + else { + if (dateTime.year>year) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid year!\r\n",dateTime.year); ++ sprintf(buf," - %u: Invalid year!\n",dateTime.year); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1573,14 +1573,14 @@ + + if (dateTime.month<1 || dateTime.month>12) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid month!\r\n",dateTime.month); ++ sprintf(buf," - %u: Invalid month!\n",dateTime.month); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } + + if (dateTime.day<1 || dateTime.day>31) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid day!\r\n",dateTime.day); ++ sprintf(buf," - %u: Invalid day!\n",dateTime.day); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1588,7 +1588,7 @@ + if (dateTime.month==2) { + if (dateTime.day>29) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid day for February!\r\n",dateTime.day); ++ sprintf(buf," - %u: Invalid day for February!\n",dateTime.day); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1596,7 +1596,7 @@ + if (dateTime.day==29) { + if ((dateTime.year%4)!=0) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid day for February, year is not a leap year(%u)!\r\n",dateTime.day, dateTime.year); ++ sprintf(buf," - %u: Invalid day for February, year is not a leap year(%u)!\n",dateTime.day, dateTime.year); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +@@ -1605,21 +1605,21 @@ + + if (dateTime.hours>23) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid hour!\r\n",dateTime.hours); ++ sprintf(buf," - %u: Invalid hour!\n",dateTime.hours); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } + + if (dateTime.minutes>59) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid minutes!\r\n",dateTime.minutes); ++ sprintf(buf," - %u: Invalid minutes!\n",dateTime.minutes); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } + + if (dateTime.seconds>59) { + sReport += icValidateWarningMsg; +- sprintf(buf," - %u: Invalid seconds!\r\n",dateTime.hours); ++ sprintf(buf," - %u: Invalid seconds!\n",dateTime.hours); + sReport += buf; + rv = icMaxStatus(rv, icValidateWarning); + } +--- SampleICC-1.3.2/IccProfLib/IccTagProfSeqId.cpp.oosrc 2007-09-13 17:38:15.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccTagProfSeqId.cpp 2007-09-13 17:47:56.000000000 +0200 +@@ -234,7 +234,7 @@ + { + std::string Dump; + +- sDescription += "ProfileID:\r\n"; ++ sDescription += "ProfileID:\n"; + + int i; + char buf[20]; +@@ -244,12 +244,12 @@ + sprintf(buf, "%2x", m_profileID.ID8[i]); + sDescription += buf; + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + +- sDescription += "Description:\r\n"; ++ sDescription += "Description:\n"; + m_desc.Describe(sDescription); + +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +@@ -434,21 +434,21 @@ + { + icChar buf[128]; + +- sprintf(buf, "BEGIN ProfileSequenceIdentification_TAG\r\n"); ++ sprintf(buf, "BEGIN ProfileSequenceIdentification_TAG\n"); + sDescription += buf; +- sDescription += "\r\n"; ++ sDescription += "\n"; + + int i; + CIccProfileIdDescList::iterator j; + for (i=0, j=m_list->begin(); j!=m_list->end(); i++, j++) { +- sprintf(buf, "ProfileDescription_%d:\r\n", i+1); ++ sprintf(buf, "ProfileDescription_%d:\n", i+1); + sDescription += buf; + j->Describe(sDescription); + } + +- sprintf(buf, "END ProfileSequenceIdentification_TAG\r\n"); ++ sprintf(buf, "END ProfileSequenceIdentification_TAG\n"); + sDescription += buf; +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + +--- SampleICC-1.3.2/IccProfLib/IccMpeBasic.cpp.oosrc 2007-08-20 22:05:00.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/IccProfLib/IccMpeBasic.cpp 2007-09-13 17:41:27.000000000 +0200 +@@ -218,43 +218,43 @@ + sprintf(buf, "%.8f", m_endPoint); + sDescription += buf; + } +- sprintf(buf, "]\r\nFunctionType: %04Xh\r\n", m_nFunctionType); ++ sprintf(buf, "]\nFunctionType: %04Xh\n", m_nFunctionType); + sDescription += buf; + + switch(m_nFunctionType) { + case 0x0000: + if (m_params[1]==0.0 && m_params[2]==0.0) +- sprintf(buf, "Y = %.8f\r\n\r\n", m_params[3]); ++ sprintf(buf, "Y = %.8f\n\n", m_params[3]); + else if (m_params[0]==1.0 && m_params[1]==1.0 && m_params[2]==0.0 && m_params[3]==0.0) +- sprintf(buf, "Y = X\r\n\r\n"); ++ sprintf(buf, "Y = X\n\n"); + else if (m_params[0]==1.0 && m_params[2]==0.0) +- sprintf(buf, "Y = %.8f * X + %.8f\r\n\r\n", ++ sprintf(buf, "Y = %.8f * X + %.8f\n\n", + m_params[1], m_params[3]); + else +- sprintf(buf, "Y = (%.8f * X + %.8f)^%.4f + %.8f\r\n\r\n", ++ sprintf(buf, "Y = (%.8f * X + %.8f)^%.4f + %.8f\n\n", + m_params[1], m_params[2], m_params[0], m_params[3]); + sDescription += buf; + return; + + case 0x0001: +- sprintf(buf, "Y = %.8f * log (%.8f * (X ^ %.8f) + %.8f) + %.8f\r\n\r\n", ++ sprintf(buf, "Y = %.8f * log (%.8f * (X ^ %.8f) + %.8f) + %.8f\n\n", + m_params[1], m_params[2], m_params[0], m_params[3], m_params[4]); + sDescription += buf; + return; + + case 0x0002: +- sprintf(buf, "Y = %.8f * (%.8f ^ (%.8f * X + %.8f)) + %.8f\r\n\r\n", ++ sprintf(buf, "Y = %.8f * (%.8f ^ (%.8f * X + %.8f)) + %.8f\n\n", + m_params[0], m_params[1], m_params[2], m_params[3], m_params[4]); + sDescription += buf; + return; + + default: + int i; +- sprintf(buf, "Unknown Function with %d parameters:\r\n\r\n", m_nParameters); ++ sprintf(buf, "Unknown Function with %d parameters:\n\n", m_nParameters); + sDescription += buf; + + for (i=0; i<m_nParameters; i++) { +- sprintf(buf, "Param[%d] = %.8lf\r\n\r\n", i, m_params[i]); ++ sprintf(buf, "Param[%d] = %.8lf\n\n", i, m_params[i]); + sDescription += buf; + } + } +@@ -496,7 +496,7 @@ + if (m_nReserved || m_nReserved2) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " formula curve has non zero reserved data.\r\n"; ++ sReport += " formula curve has non zero reserved data.\n"; + rv = icValidateWarning; + } + +@@ -505,13 +505,13 @@ + if (!m_params || m_nParameters<4) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " formula curve has Invalid formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has Invalid formulaCurveSegment parameters.\n"; + rv = icValidateCriticalError; + } + else if (m_nParameters > 4) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " formula curve has too many formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has too many formulaCurveSegment parameters.\n"; + rv = icValidateWarning; + } + break; +@@ -520,13 +520,13 @@ + if (!m_params || m_nParameters<5) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " formula curve has Invalid formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has Invalid formulaCurveSegment parameters.\n"; + rv = icValidateCriticalError; + } + else if (m_nParameters > 5) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " formula curve has too many formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has too many formulaCurveSegment parameters.\n"; + rv = icValidateWarning; + } + break; +@@ -535,13 +535,13 @@ + if (!m_params || m_nParameters<5) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " formula curve has Invalid formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has Invalid formulaCurveSegment parameters.\n"; + rv = icValidateCriticalError; + } + else if (m_nParameters > 5) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " formula curve has too many formulaCurveSegment parameters.\r\n"; ++ sReport += " formula curve has too many formulaCurveSegment parameters.\n"; + rv = icValidateWarning; + } + break; +@@ -551,7 +551,7 @@ + icChar buf[128]; + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sprintf(buf, " formula curve uses unknown formulaCurveSegment function type %d\r\n", m_nFunctionType); ++ sprintf(buf, " formula curve uses unknown formulaCurveSegment function type %d\n", m_nFunctionType); + sReport += buf; + rv = icValidateCriticalError; + } +@@ -727,7 +727,7 @@ + sDescription += buf; + } + +- sprintf(buf, "]\r\n"); ++ sprintf(buf, "]\n"); + sDescription += buf; + } + else { +@@ -744,9 +744,9 @@ + sprintf(buf, "%.8f", m_endPoint); + sDescription += buf; + } +- sprintf(buf, "]\r\n"); ++ sprintf(buf, "]\n"); + sDescription += buf; +- sDescription += "IN OUT\r\n"; ++ sDescription += "IN OUT\n"; + + icUInt32Number i; + +@@ -754,11 +754,11 @@ + icFloatNumber last = (icFloatNumber)(m_nCount-1); + + for (i=0; i<m_nCount; i++) { +- sprintf(buf, "%.8f %.8f\r\n", m_startPoint + (icFloatNumber)i*range/last, m_pSamples[i]); ++ sprintf(buf, "%.8f %.8f\n", m_startPoint + (icFloatNumber)i*range/last, m_pSamples[i]); + sDescription += buf; + } + } +- sDescription += "\r\n"; ++ sDescription += "\n"; + } + + /** +@@ -910,20 +910,20 @@ + if (m_nReserved) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " sampled curve has non zero reserved data.\r\n"; ++ sReport += " sampled curve has non zero reserved data.\n"; + rv = icValidateWarning; + } + + if (m_nCount<2) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " sampled curve has too few sample points.\r\n"; ++ sReport += " sampled curve has too few sample points.\n"; + rv = icValidateCriticalError; + } + else if (m_endPoint-m_startPoint == 0.0) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " sampled curve has a range of zero.\r\n"; ++ sReport += " sampled curve has a range of zero.\n"; + rv = icMaxStatus(rv, icValidateWarning); + } + +@@ -1054,7 +1054,7 @@ + { + CIccCurveSegmentList::iterator i; + +- sDescription += "BEGIN_CURVE\r\n"; ++ sDescription += "BEGIN_CURVE\n"; + for (i=m_list->begin(); i!=m_list->end(); i++) { + (*i)->Describe(sDescription); + } +@@ -1342,14 +1342,14 @@ + if (m_nReserved1 || m_nReserved2) { + sReport += icValidateWarningMsg; + sReport += sSigName; +- sReport += " Segmented curve has non zero reserved data.\r\n"; ++ sReport += " Segmented curve has non zero reserved data.\n"; + rv = icValidateWarning; + } + + if (m_list->size()==0) { + sReport += icValidateCriticalErrorMsg; + sReport += sSigName; +- sReport += " Has Empty CurveSegment!\r\n"; ++ sReport += " Has Empty CurveSegment!\n"; + return icValidateCriticalError; + } + +@@ -1599,11 +1599,11 @@ + icChar buf[81]; + int i; + +- sprintf(buf, "BEGIN_CURVE_SET %d\r\n", m_nInputChannels); ++ sprintf(buf, "BEGIN_CURVE_SET %d\n", m_nInputChannels); + sDescription += buf; + + for (i=0; i<m_nInputChannels; i++) { +- sprintf(buf, "Curve %d of %d\r\n", i+1, m_nInputChannels); ++ sprintf(buf, "Curve %d of %d\n", i+1, m_nInputChannels); + sDescription += buf; + if (m_curve[i]) { + m_curve[i]->Describe(sDescription); +@@ -1877,7 +1877,7 @@ + sReport += " - Element "; + sSigName = Info.GetSigName(GetType()); + sReport += sSigName; +- sReport += " Has Empty Curve Element(s)!\r\n"; ++ sReport += " Has Empty Curve Element(s)!\n"; + return icValidateCriticalError; + } + +@@ -2042,7 +2042,7 @@ + int i, j; + icFloatNumber *data = m_pMatrix; + +- sprintf(buf, "BEGIN_ELEM_MATRIX %d %d\r\n", m_nInputChannels, m_nOutputChannels); ++ sprintf(buf, "BEGIN_ELEM_MATRIX %d %d\n", m_nInputChannels, m_nOutputChannels); + sDescription += buf; + + for (j=0; j<m_nOutputChannels; j++) { +@@ -2052,7 +2052,7 @@ + sprintf(buf, "%12.8lf", data[i]); + sDescription += buf; + } +- sprintf(buf, " + %12.8lf\r\n", m_pConstants[j]); ++ sprintf(buf, " + %12.8lf\n", m_pConstants[j]); + sDescription += buf; + data += i; + } +@@ -2273,7 +2273,7 @@ + sReport += " - Element "; + sSigName = Info.GetSigName(GetType()); + sReport += sSigName; +- sReport += " Has Empty Matrix data!\r\n"; ++ sReport += " Has Empty Matrix data!\n"; + return icValidateCriticalError; + } + +@@ -2620,7 +2620,7 @@ + sReport += " - Element "; + sSigName = Info.GetSigName(GetType()); + sReport += sSigName; +- sReport += " Has No CLUT!\r\n"; ++ sReport += " Has No CLUT!\n"; + return icValidateCriticalError; + } + +--- SampleICC-1.3.2/Contrib/ICC_utils/Makefile.in.oo1 2007-08-20 22:10:35.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/Contrib/ICC_utils/Makefile.in 2007-09-13 17:11:41.000000000 +0200 +@@ -133,7 +133,7 @@ + CONFIG_CLEAN_FILES = + LTLIBRARIES = $(lib_LTLIBRARIES) + +-libICC_utils_la_LIBADD = ++libICC_utils_la_LIBADD = $(LDADD) + am_libICC_utils_la_OBJECTS = Stubs.lo CAT.lo CLUT.lo CLUT_stuffer.lo \ + ICC_tool_exception.lo Vetters.lo + libICC_utils_la_OBJECTS = $(am_libICC_utils_la_OBJECTS) +--- SampleICC-1.3.2/Contrib/CmdLine/Makefile.in.oo1 2007-08-20 22:10:34.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/Contrib/CmdLine/Makefile.in 2007-09-13 17:11:41.000000000 +0200 +@@ -102,15 +102,11 @@ + install_sh = @install_sh@ + + SUBDIRS = \ +- create_CLUT_profile \ +- create_CLUT_profile_from_probe \ +- create_display_profile ++ create_sRGB_profile + + + DIST_SUBDIRS = \ +- create_CLUT_profile \ +- create_CLUT_profile_from_probe \ +- create_display_profile ++ create_sRGB_profile + + subdir = Contrib/CmdLine + mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs +--- SampleICC-1.3.2/Contrib/Makefile.in.oo1 2007-08-20 22:10:37.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/Contrib/Makefile.in 2007-09-13 17:11:41.000000000 +0200 +@@ -103,18 +103,12 @@ + + SUBDIRS = \ + ICC_utils \ +- CmdLine \ +- examples \ +- Mac_OS_X \ +- tests ++ CmdLine + + + DIST_SUBDIRS = \ + ICC_utils \ +- CmdLine \ +- examples \ +- Mac_OS_X \ +- tests ++ CmdLine + + subdir = Contrib + mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs +--- SampleICC-1.3.2/Tools/CmdLine/Makefile.in.oo1 2007-08-20 22:10:42.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/Tools/CmdLine/Makefile.in 2007-09-13 17:11:41.000000000 +0200 +@@ -101,17 +101,13 @@ + am__quote = @am__quote@ + install_sh = @install_sh@ + +-SUBDIRS = IccApplyNamedCmm \ +- @SICC_ICC_APPLY_PROFILES@ \ +- IccDumpProfile \ ++SUBDIRS = IccDumpProfile \ + IccProfLibTest \ + IccStripUnknownTags \ + IccV4ToMPE + + +-DIST_SUBDIRS = IccApplyNamedCmm \ +- IccApplyProfiles \ +- IccDumpProfile \ ++DIST_SUBDIRS = IccDumpProfile \ + IccProfLibTest \ + IccStripUnknownTags \ + IccV4ToMPE +--- SampleICC-1.3.2/configure.oo1 2007-08-20 22:10:59.000000000 +0200 ++++ misc/build/SampleICC-1.3.2/configure 2007-09-13 17:11:41.000000000 +0200 +@@ -19991,7 +19991,7 @@ + + + +- ac_config_files="$ac_config_files Makefile IccProfLib/Makefile Tools/Makefile Tools/CmdLine/Makefile Tools/CmdLine/IccApplyNamedCmm/Makefile Tools/CmdLine/IccApplyProfiles/Makefile Tools/CmdLine/IccDumpProfile/Makefile Tools/CmdLine/IccProfLibTest/Makefile Tools/CmdLine/IccStripUnknownTags/Makefile Tools/CmdLine/IccV4ToMPE/Makefile Contrib/Makefile Contrib/CmdLine/Makefile Contrib/CmdLine/create_CLUT_profile/Makefile Contrib/CmdLine/create_CLUT_profile_from_probe/Makefile Contrib/CmdLine/create_display_profile/Makefile Contrib/ICC_utils/Makefile Contrib/Mac_OS_X/Makefile Contrib/Mac_OS_X/create_probe/Makefile Contrib/Mac_OS_X/extract_probe_data/Makefile Contrib/examples/Makefile Contrib/examples/RSR/Makefile Contrib/tests/Makefile Contrib/tests/flatten_AToB_tag/Makefile Contrib/tests/generate_device_codes/Makefile Contrib/tests/reconstruct_measurements/Makefile Contrib/tests/round_trip_PCS_LAB/Makefile" ++ ac_config_files="$ac_config_files Makefile IccProfLib/Makefile Tools/Makefile Tools/CmdLine/Makefile Tools/CmdLine/IccDumpProfile/Makefile Tools/CmdLine/IccProfLibTest/Makefile Tools/CmdLine/IccStripUnknownTags/Makefile Tools/CmdLine/IccV4ToMPE/Makefile Contrib/Makefile Contrib/CmdLine/Makefile Contrib/ICC_utils/Makefile Contrib/CmdLine/create_sRGB_profile/Makefile" + cat >confcache <<\_ACEOF + # This file is a shell script that caches the results of configure + # tests run on this system so they can be shared between configure +@@ -20571,28 +20571,14 @@ + "IccProfLib/Makefile" ) CONFIG_FILES="$CONFIG_FILES IccProfLib/Makefile" ;; + "Tools/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/Makefile" ;; + "Tools/CmdLine/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/Makefile" ;; +- "Tools/CmdLine/IccApplyNamedCmm/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccApplyNamedCmm/Makefile" ;; +- "Tools/CmdLine/IccApplyProfiles/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccApplyProfiles/Makefile" ;; + "Tools/CmdLine/IccDumpProfile/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccDumpProfile/Makefile" ;; + "Tools/CmdLine/IccProfLibTest/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccProfLibTest/Makefile" ;; + "Tools/CmdLine/IccStripUnknownTags/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccStripUnknownTags/Makefile" ;; + "Tools/CmdLine/IccV4ToMPE/Makefile" ) CONFIG_FILES="$CONFIG_FILES Tools/CmdLine/IccV4ToMPE/Makefile" ;; + "Contrib/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/Makefile" ;; + "Contrib/CmdLine/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/CmdLine/Makefile" ;; +- "Contrib/CmdLine/create_CLUT_profile/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/CmdLine/create_CLUT_profile/Makefile" ;; +- "Contrib/CmdLine/create_CLUT_profile_from_probe/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/CmdLine/create_CLUT_profile_from_probe/Makefile" ;; +- "Contrib/CmdLine/create_display_profile/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/CmdLine/create_display_profile/Makefile" ;; ++ "Contrib/CmdLine/create_sRGB_profile/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/CmdLine/create_sRGB_profile/Makefile" ;; + "Contrib/ICC_utils/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/ICC_utils/Makefile" ;; +- "Contrib/Mac_OS_X/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/Mac_OS_X/Makefile" ;; +- "Contrib/Mac_OS_X/create_probe/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/Mac_OS_X/create_probe/Makefile" ;; +- "Contrib/Mac_OS_X/extract_probe_data/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/Mac_OS_X/extract_probe_data/Makefile" ;; +- "Contrib/examples/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/examples/Makefile" ;; +- "Contrib/examples/RSR/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/examples/RSR/Makefile" ;; +- "Contrib/tests/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/tests/Makefile" ;; +- "Contrib/tests/flatten_AToB_tag/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/tests/flatten_AToB_tag/Makefile" ;; +- "Contrib/tests/generate_device_codes/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/tests/generate_device_codes/Makefile" ;; +- "Contrib/tests/reconstruct_measurements/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/tests/reconstruct_measurements/Makefile" ;; +- "Contrib/tests/round_trip_PCS_LAB/Makefile" ) CONFIG_FILES="$CONFIG_FILES Contrib/tests/round_trip_PCS_LAB/Makefile" ;; + "depfiles" ) CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; + *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 + echo "$as_me: error: invalid argument: $ac_config_target" >&2;} diff --git a/icc/makefile.mk b/icc/makefile.mk new file mode 100644 index 000000000000..83db4115a88d --- /dev/null +++ b/icc/makefile.mk @@ -0,0 +1,68 @@ +#************************************************************************* +# +# OpenOffice.org - a multi-platform office productivity suite +# +# $RCSfile: makefile.mk,v $ +# +# $Revision: 1.2 $ +# +# last change: $Author: pl $ $Date: 2008-01-10 15:38:31 $ +# +# The Contents of this file are made available subject to +# the terms of GNU Lesser General Public License Version 2.1. +# +# +# GNU Lesser General Public License Version 2.1 +# ============================================= +# Copyright 2005 by Sun Microsystems, Inc. +# 901 San Antonio Road, Palo Alto, CA 94303, USA +# +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public +# License version 2.1, as published by the Free Software Foundation. +# +# This library is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 59 Temple Place, Suite 330, Boston, +# MA 02111-1307 USA +# +#************************************************************************* + +PRJ=. + +PRJNAME=icc +TARGET=icc + +# --- Settings ----------------------------------------------------- + +.INCLUDE : settings.mk + +# --- Files -------------------------------------------------------- + +TARFILE_NAME=SampleICC-1.3.2 +PATCH_FILE_NAME=$(TARFILE_NAME).patch +BUILD_ACTION=$(GNUMAKE) && cd Contrib/CmdLine/create_sRGB_profile && ./create_sRGB_profile +CONVERTFILES= \ + IccProfLib/IccTagProfSeqId.h \ + IccProfLib/IccTagProfSeqId.cpp \ + Contrib/ICC_utils/Stubs.h \ + Contrib/ICC_utils/Vetters.cpp + +.IF "$(GUI)"=="WNT" +CONFIGURE_ACTION= $(COPY) -r $(BACK_PATH)../source/create_sRGB_profile Contrib/CmdLine && CC="" CXX="" ./configure +.ELSE +CONFIGURE_ACTION= $(COPY) -r $(BACK_PATH)../source/create_sRGB_profile Contrib/CmdLine && ./configure +.ENDIF + +# --- Targets ------------------------------------------------------ + +.INCLUDE : set_ext.mk +.INCLUDE : target.mk +.INCLUDE : tg_ext.mk + + diff --git a/icc/prj/build.lst b/icc/prj/build.lst new file mode 100644 index 000000000000..7ce035bd4d92 --- /dev/null +++ b/icc/prj/build.lst @@ -0,0 +1,3 @@ +ip icc : solenv external NULL +ip icc usr1 - all ip_mkout NULL +ip icc nmake - all ip_icc NULL diff --git a/icc/prj/d.lst b/icc/prj/d.lst new file mode 100644 index 000000000000..864e9473792b --- /dev/null +++ b/icc/prj/d.lst @@ -0,0 +1,5 @@ +mkdir: %_DEST%\inc%_EXT%\icc +mkdir: %_DEST%\inc%_EXT%\external\icc + +..\%__SRC%\misc\build\SampleICC*\Contrib\CmdLine\create_sRGB_profile\sRGB*.hxx %_DEST%\inc%_EXT%\icc\sRGB*.hxx + diff --git a/icc/source/create_sRGB_profile/create_sRGB_profile.cpp b/icc/source/create_sRGB_profile/create_sRGB_profile.cpp index eef7a8c9b96d..deece8cdede6 100644 --- a/icc/source/create_sRGB_profile/create_sRGB_profile.cpp +++ b/icc/source/create_sRGB_profile/create_sRGB_profile.cpp @@ -4,9 +4,9 @@ * * $RCSfile: create_sRGB_profile.cpp,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: beppec56 $ $Date: 2007-12-09 10:19:51 $ + * last change: $Author: pl $ $Date: 2008-01-10 15:39:13 $ Derived by beppec56@openoffice.org from various examples in SampleICC library, the original copyright retained. @@ -89,7 +89,7 @@ using namespace std; const char * const icc_file_name = "sRGB-IEC61966-2.1.icc"; const char * const hxx_file_name = "sRGB-IEC61966-2.1.hxx"; -const char * const this_file_name_and_location =" * external/icc/source/create_sRGB_profile/create_sRGB_profile.cpp"; +const char * const this_file_name_and_location =" * icc/source/create_sRGB_profile/create_sRGB_profile.cpp"; const char* const description = "sRGB IEC61966-2.1"; //const char* const devicemanufact = "IEC http://www.iec.ch"; not used, device manufactured by OOo seems funny... @@ -99,10 +99,10 @@ const char* const copyright = "The Contents of this file are made available subj // the creation date is fixed, corresponds to the last time this file has been changed // NOTE: change this date values whenever the data inside the profile are changed. const int data_last_changed_year = 2007; -const int data_last_changed_month = 8; -const int data_last_day = 31; -const int data_last_changed_hour = 14; -const int data_last_changed_minute = 9; +const int data_last_changed_month = 12; +const int data_last_day = 12; +const int data_last_changed_hour = 18; +const int data_last_changed_minute = 32; // the following string array it's the standard OOo header format const char * const TheHeader1[] = @@ -149,9 +149,12 @@ const char * const TheHeader2[] = "#define INCLUDED_ICC_SRGB_IEC61966_2_1_H", "", "/***********************************************************************", - " * this file is automatically generated by file", + " * NOTE:", + " * this file is automatically generated by running the program", + " * obtained building:", this_file_name_and_location, - " * modify that file if you need to change something", + " * contained in module icc", + " * modify that program if you need to change something.", " ***********************************************************************/", NULL // last string, a null }; @@ -162,7 +165,7 @@ const char * const TheTail[] = NULL }; -icFloatNumber computeIECRGBtoXYZ( icFloatNumber indata ) +icFloatNumber computeIEC_RGBtoXYZ( icFloatNumber indata ) { double retval = 0.0; if(indata < 0.04045) @@ -196,7 +199,7 @@ void dumpTag(FILE *outfile, CIccProfile *pIcc, icTagSignature sig) if (pTag) { fprintf(outfile, "\nContents of %s tag (%s)\n", Fmt.GetTagSigName(sig), icGetSig(buf, sig)); - fprintf(outfile,"outfile, Type: "); + fprintf(outfile,"Type: "); if (pTag->IsArrayType()) fprintf(outfile, "Array of "); @@ -279,34 +282,8 @@ int main(int argc, char* argv[]) try { - int N = 1024; // number of points in LUTs - const char* const out_file_pathname = icc_file_name; - icFloatNumber measuredBlack[3]; - icFloatNumber measuredWhite[3]; - - measuredBlack[0] = 0.0; - measuredBlack[1] = 0.0; - measuredBlack[2] = 0.0; - - measuredWhite[0] = 0.3127; - measuredWhite[1] = 0.3290; - measuredWhite[2] = 0.3583; - - icFloatNumber* redTRC = new icFloatNumber[N]; - icFloatNumber* greenTRC = new icFloatNumber[N]; - icFloatNumber* blueTRC = new icFloatNumber[N]; - int i; - for (i = 0; i < N; ++i) - { - // apply conversion from RGB to XYZ, moving the RGB value linearly from 0 to 100% - // 1024 steps are computed - redTRC[i] = computeIECRGBtoXYZ( (icFloatNumber)i/(N-1)); - greenTRC[i] = redTRC[i]; - blueTRC[i] = redTRC[i]; - } - CIccProfile profile; profile.InitHeader(); @@ -329,82 +306,57 @@ int main(int argc, char* argv[]) profile.m_Header.version=icVersionNumberV2_1; - // Required tags for a three-component matrix-based display profile, as layed - // out in the ICC spec [sections 8.2 and 8.4.3] are: - // profileDescriptionTag + // Required tags for a three-component matrix-based display profile, as laid + // out by specification ICC.1:1998-09 (clause 6.3) are: + // // copyrightTag - // mediaWhitePointTag - // chromaticAdaptationTag + // profileDescriptionTag // redMatrixColumnTag // greenMatrixColumnTag // blueMatrixColumnTag // redTRCTag // greenTRCTag // blueTRCTag + // mediaWhitePointTag - // profileDescriptionTag - CIccTagTextDescription* descriptionTag = new CIccTagTextDescription; - descriptionTag->SetText(description); - profile.AttachTag(icSigProfileDescriptionTag, descriptionTag); + // the other tags: + // + // technologyTag + // deviceModelTag + // deviceMfgDescTag + // mediaBlackPointTag + // viewingCondDescTag + // viewingConditionsTag + // luminanceTag + // measurementTag + // + // are optionals, added for completeness - //device model tag - CIccTagTextDescription* deviceModelTag = new CIccTagTextDescription; - deviceModelTag->SetText("IEC 61966-2.1 Default RGB colour space - sRGB "); - profile.AttachTag( icSigDeviceModelDescTag, deviceModelTag); + // the element below are sorted in the same order as + // the list above, but the LUT table, + // embedded at the end of the profile // copyrightTag CIccTagText* copyrightTag = new CIccTagText; copyrightTag->SetText(copyright); profile.AttachTag(icSigCopyrightTag, copyrightTag); - //device signature - CIccTagSignature* deviceSign = new CIccTagSignature; - deviceSign->SetValue( icSigCRTDisplay ); - profile.AttachTag( icSigTechnologyTag, deviceSign ); - - // For displays, and for projected imagery in cinema, we assume complete - // adaptation on the part of the viewer, and we treat the medium white - // as the illuminant. - icFloatNumber illuminantY = measuredWhite[1]; - icFloatNumber normalizedIlluminant[3]; - for (i = 0; i < 3; ++i) - normalizedIlluminant[i] = measuredWhite[i] / illuminantY; - CAT* CATToD50 = new CAT(icD50XYZ, normalizedIlluminant); - - icFloatNumber flare[3] = { 0, 0, 0 }; // perhaps oversimplified but... - - // mediaWhitePointTag - CIccTagXYZ* whitePointTag = new CIccTagXYZ; - icFloatNumber adaptedMediaWhite[3]; - CLUT::measuredXYZToAdaptedXYZ(adaptedMediaWhite, measuredWhite, - flare, illuminantY, CATToD50); - (*whitePointTag)[0].X = icDtoF(adaptedMediaWhite[0]); - (*whitePointTag)[0].Y = icDtoF(adaptedMediaWhite[1]); - (*whitePointTag)[0].Z = icDtoF(adaptedMediaWhite[2]); - profile.AttachTag(icSigMediaWhitePointTag, whitePointTag); - - // mediaBlackPointTag - CIccTagXYZ* blackPointTag = new CIccTagXYZ; - icFloatNumber adaptedMediaBlack[3]; - CLUT::measuredXYZToAdaptedXYZ(adaptedMediaBlack, measuredBlack, - flare, illuminantY, CATToD50); - (*blackPointTag)[0].X = icDtoF(adaptedMediaBlack[0]); - (*blackPointTag)[0].Y = icDtoF(adaptedMediaBlack[1]); - (*blackPointTag)[0].Z = icDtoF(adaptedMediaBlack[2]); - profile.AttachTag(icSigMediaBlackPointTag, blackPointTag); - // chromaticAdaptationTag - CIccTagS15Fixed16* chromaticAdaptationTag = CATToD50->makeChromaticAdaptationTag(); - profile.AttachTag(icSigChromaticAdaptationTag, chromaticAdaptationTag); + // profileDescriptionTag + CIccTagTextDescription* descriptionTag = new CIccTagTextDescription; + descriptionTag->SetText(description); + profile.AttachTag(icSigProfileDescriptionTag, descriptionTag); CIccTagXYZ* redMatrixColumnTag = new CIccTagXYZ; //values from raccomandation of ICC for sRGB, D50 referenced characterisation data - (*redMatrixColumnTag)[0].X = icDtoF(0.4360); + //should be: 0.4361, 0.2225, 0.0139 according to application notes, + // the 'X' value below is the one commonly in use on a very + // diffused sRGB profile + (*redMatrixColumnTag)[0].X = icDtoF(0.4361); (*redMatrixColumnTag)[0].Y = icDtoF(0.2225); (*redMatrixColumnTag)[0].Z = icDtoF(0.0139); profile.AttachTag(icSigRedMatrixColumnTag, redMatrixColumnTag); CIccTagXYZ* greenMatrixColumnTag = new CIccTagXYZ; - //values from raccomandation of ICC for sRGB, D50 referenced characterisation data (*greenMatrixColumnTag)[0].X = icDtoF(0.3851); (*greenMatrixColumnTag)[0].Y = icDtoF(0.7169); @@ -412,36 +364,95 @@ int main(int argc, char* argv[]) profile.AttachTag(icSigGreenMatrixColumnTag, greenMatrixColumnTag); CIccTagXYZ* blueMatrixColumnTag = new CIccTagXYZ; - //values from raccomandation of ICC for sRGB, D50 referenced characterisation data + //should be: 0.1431, 0.0606, 0.7139 according to application notes, + // the 'Z' value below is the one commonly in use on a very + // diffused sRGB profile (*blueMatrixColumnTag)[0].X = icDtoF(0.1431); (*blueMatrixColumnTag)[0].Y = icDtoF(0.0606); - (*blueMatrixColumnTag)[0].Z = icDtoF(0.7139); + (*blueMatrixColumnTag)[0].Z = icDtoF(0.7141); profile.AttachTag(icSigBlueMatrixColumnTag, blueMatrixColumnTag); - CIccTagCurve* redTRCTag = new CIccTagCurve(N); - if (N == 1) - redTRCTag->SetGamma(redTRC[0]); - else - for (i = 0; i < N; ++i) - (*redTRCTag)[i] = redTRC[i]; - profile.AttachTag(icSigRedTRCTag, redTRCTag); + // mediaWhitePointTag + CIccTagXYZ* whitePointTag = new CIccTagXYZ; + (*whitePointTag)[0].X = icDtoF(0.9505); + (*whitePointTag)[0].Y = icDtoF(1.0); + (*whitePointTag)[0].Z = icDtoF(1.0891); + profile.AttachTag(icSigMediaWhitePointTag, whitePointTag); - CIccTagCurve* greenTRCTag = new CIccTagCurve(N); - if (N == 1) - greenTRCTag->SetGamma(greenTRC[0]); - else - for (i = 0; i < N; ++i) - (*greenTRCTag)[i] = greenTRC[i]; - profile.AttachTag(icSigGreenTRCTag, greenTRCTag); + //device signature (technologytag) + CIccTagSignature* deviceSign = new CIccTagSignature; + deviceSign->SetValue( icSigCRTDisplay ); + profile.AttachTag( icSigTechnologyTag, deviceSign ); - CIccTagCurve* blueTRCTag = new CIccTagCurve(N); - if (N == 1) - blueTRCTag->SetGamma(blueTRC[0]); - else - for (i = 0; i < N; ++i) - (*blueTRCTag)[i] = blueTRC[i]; - profile.AttachTag(icSigBlueTRCTag, blueTRCTag); + //device model tag + CIccTagTextDescription* deviceModelTag = new CIccTagTextDescription; + deviceModelTag->SetText("IEC 61966-2.1 Default RGB colour space - sRGB"); + profile.AttachTag( icSigDeviceModelDescTag, deviceModelTag); + + // deviceMfgDescTag + CIccTagTextDescription* deviceMfgTag = new CIccTagTextDescription; + deviceMfgTag->SetText("IEC http://www.iec.ch"); + profile.AttachTag( icSigDeviceMfgDescTag, deviceMfgTag); + + // mediaBlackPointTag + CIccTagXYZ* blackPointTag = new CIccTagXYZ; + (*blackPointTag)[0].X = + (*blackPointTag)[0].Y = + (*blackPointTag)[0].Z = icDtoF(0.0); + profile.AttachTag(icSigMediaBlackPointTag, blackPointTag); + + // viewingCondDescTag + CIccTagTextDescription* viewingCondDescTag = new CIccTagTextDescription; + viewingCondDescTag->SetText("Reference viewing condition according to IEC 61966-2.1"); + profile.AttachTag( icSigViewingCondDescTag, viewingCondDescTag ); + + // viewingConditionsTag + CIccTagViewingConditions* viewingConditionsTag = new CIccTagViewingConditions; + // Illuminant tristimulus value + (*viewingConditionsTag).m_XYZIllum.X = icDtoF(19.6445); + (*viewingConditionsTag).m_XYZIllum.Y = icDtoF(20.3718); + (*viewingConditionsTag).m_XYZIllum.Z = icDtoF(16.8089); + // surround tristimulus value + (*viewingConditionsTag).m_XYZSurround.X = icDtoF(3.9289); + (*viewingConditionsTag).m_XYZSurround.Y = icDtoF(4.0744); + (*viewingConditionsTag).m_XYZSurround.Z = icDtoF(3.3618); + (*viewingConditionsTag).m_illumType = icIlluminantD50; + profile.AttachTag( icSigViewingConditionsType, viewingConditionsTag ); + + // luminanceTag + CIccTagXYZ* luminanceTag = new CIccTagXYZ; + (*luminanceTag)[0].X = icDtoF(76.0365); + (*luminanceTag)[0].Y = icDtoF(80.0); + (*luminanceTag)[0].Z = icDtoF(87.1246); + profile.AttachTag(icSigLuminanceTag, luminanceTag); + + // measurementTag + CIccTagMeasurement* measurementTag = new CIccTagMeasurement; + (*measurementTag).m_Data.stdObserver = icStdObs1931TwoDegrees; + (*measurementTag).m_Data.backing.X = + (*measurementTag).m_Data.backing.Y = + (*measurementTag).m_Data.backing.Z = icDtoF(0.0); + (*measurementTag).m_Data.geometry = icGeometryUnknown; + // the flare is 1%, but the library doesn't seem all right with this + // see specification ICC.1:1998-09, clause 6.5.8, table 55 fot the right + // format of the data value + (*measurementTag).m_Data.flare = static_cast< icMeasurementFlare > ( icDtoUF( 0.01 ) );//means 1% + (*measurementTag).m_Data.illuminant = icIlluminantD65; + profile.AttachTag(icSigMeasurementTag, measurementTag ); + + // compute the LUT curves, they are equal for all three colors + // so only one LUT is computed and stored + int N = 1024; // number of points in LUTs + CIccTagCurve* colorTRCTag = new CIccTagCurve(N); + // apply conversion from RGB to XYZ, stepping the RGB value linearly from 0 to 100% + // 1024 steps are computed + for (int i = 0; i < N; ++i) + (*colorTRCTag)[i] = computeIEC_RGBtoXYZ( (icFloatNumber)i/(N-1)); + + profile.AttachTag(icSigRedTRCTag, colorTRCTag); + profile.AttachTag(icSigGreenTRCTag, colorTRCTag); + profile.AttachTag(icSigBlueTRCTag, colorTRCTag); //Verify things string validationReport; |