>> Oh, I see... You profile forces L* to zero but keeps a* and b*,
[...] > Well... I was afraid that that would be the reason. But it means > that we cannot use the recipe in > > https://www.mail-archive.com/lcms-user@lists.sourceforge.net/msg01509.html > > to create a brightness/contrast filter that works the way our users > expect, so we need to figure out something new... I guess it would > be cheating to check the lightness curve for being all zero or all > ffff and if so, just mean the whole image white or black :-) This is from about 10 years ago, and talks about lcms1, but still is correct. Please note what Casper was asking for, is a way to modify lightness with a curve. The solution you use does exactly that. It changes L* and keeps a*/b* untouched. If your curve is all L* to zero, you obtain a resulting Lab image with L*=0 in all pixels. Exactly what you asked for. So far so good. Now when you try to convert this Lab image to RGB, you use a profile that has embedded some sort of gamut mapping. Maybe it is just a plain clipping. Many profiles chooses to represent Lab of (0, whatever, whatever) as a close color with some luma. This is completely on the ICC profile side, and has nothing to do with the algorithm you are using of forcing L*=0 Now for some advice. Colors with L*=0 and chroma not zero are in fact undefined. This is the old question about how much chroma pure black has. You really don't want that. So what I would do if I would need to handle those cases, is to use a CLUT 3D table instead of pure curves. When building the nodes, I would force all nodes with L*=100 and L*=0 to be achromatic to the media white (a*=b*=0), and then let the tetrahedral interpolation to smooth the results for you. Best regards Marti ------------------------------------------------------------------------------ _______________________________________________ Lcms-user mailing list Lcms-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/lcms-user