From ad284620cdbf67440f6cd4336be747ece15317b4 Mon Sep 17 00:00:00 2001 From: Wacton Date: Mon, 7 Oct 2024 13:42:51 +0100 Subject: [PATCH] Update README.md --- README.md | 2 +- Unicolour.Readme/README.md | 2 +- Unicolour/Icc/Channels.cs | 2 ++ Unicolour/Icc/Clut.cs | 2 +- docs/README.md | 2 +- docs/README_us.md | 2 +- 6 files changed, 7 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 874bacd..4a96048 100644 --- a/README.md +++ b/README.md @@ -390,7 +390,7 @@ var noRed = colour.SimulateProtanopia(); ### Use ICC profiles for CMYK conversion Device-dependent colour prints of 4 (e.g. FOGRA39 CMYK) or more (e.g. FOGRA55 CMYKOGV) are supported through ICC profiles. -If there is no ICC profile, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. +If no ICC profile is provided, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. ```c# using Wacton.Unicolour.Icc; diff --git a/Unicolour.Readme/README.md b/Unicolour.Readme/README.md index cf7b03b..43523d2 100644 --- a/Unicolour.Readme/README.md +++ b/Unicolour.Readme/README.md @@ -390,7 +390,7 @@ var noRed = colour.SimulateProtanopia(); ### Use ICC profiles for CMYK conversion Device-dependent colour prints of 4 (e.g. FOGRA39 CMYK) or more (e.g. FOGRA55 CMYKOGV) are supported through ICC profiles. -If there is no ICC profile, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. +If no ICC profile is provided, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. ```c# using Wacton.Unicolour.Icc; diff --git a/Unicolour/Icc/Channels.cs b/Unicolour/Icc/Channels.cs index 9c00fc1..231a352 100644 --- a/Unicolour/Icc/Channels.cs +++ b/Unicolour/Icc/Channels.cs @@ -19,6 +19,7 @@ internal static Channels FromXyz(Xyz xyz, IccConfiguration iccConfig, XyzConfigu { var profile = iccConfig.Profile!; var intent = iccConfig.Intent; + // TODO: try/catch in case ICC profile data is corrupted? var channels = profile.FromXyz(xyz, xyzConfig, intent); return new Channels(channels) { @@ -32,6 +33,7 @@ internal static Xyz ToXyz(Channels channels, IccConfiguration iccConfig, XyzConf var profile = iccConfig.Profile!; var intent = iccConfig.Intent; channels.ColourSpace = profile.Header.DataColourSpace; + // TODO: try/catch in case ICC profile data is corrupted? var xyz = profile.ToXyz(channels.Values, xyzConfig, intent); return xyz; } diff --git a/Unicolour/Icc/Clut.cs b/Unicolour/Icc/Clut.cs index 2ea5eac..16456aa 100644 --- a/Unicolour/Icc/Clut.cs +++ b/Unicolour/Icc/Clut.cs @@ -51,7 +51,7 @@ private Array InitialiseClutGrid(double[] values) /* * finds the section of the CLUT grid that is bound by the indexes of the input channels * where each coordinate that forms the bounding area is an array of output channel values - * then interpolates within that grid section to find a precise values for the output channels + * then interpolates within that grid section to find a precise value for the output channels * particularly tricky because it is generalised to N-dimensions * (Fogra39 CMYK -> LAB has a 4D CLUT grid, Fogra55 CMYKOGV has a 7D CLUT grid) * ---------- diff --git a/docs/README.md b/docs/README.md index 4695d3b..2fe1291 100644 --- a/docs/README.md +++ b/docs/README.md @@ -284,7 +284,7 @@ var noRed = colour.SimulateProtanopia(); ### Use ICC profiles for CMYK conversion Device-dependent colour prints of 4 (e.g. FOGRA39 CMYK) or more (e.g. FOGRA55 CMYKOGV) are supported through ICC profiles. -If there is no ICC profile, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. +If no ICC profile is provided, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. ```c# using Wacton.Unicolour.Icc; diff --git a/docs/README_us.md b/docs/README_us.md index ce90372..3e3f7fd 100644 --- a/docs/README_us.md +++ b/docs/README_us.md @@ -284,7 +284,7 @@ var noRed = color.SimulateProtanopia(); ### Use ICC profiles for CMYK conversion Device-dependent color prints of 4 (e.g. FOGRA39 CMYK) or more (e.g. FOGRA55 CMYKOGV) are supported through ICC profiles. -If there is no ICC profile, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. +If no ICC profile is provided, or if the profile is incompatible, naive conversion for uncalibrated CMYK is used instead. ```c# using Wacton.Unicolour.Icc;