简体   繁体   中英

How to convert from CIELab to CMYK using ColorMine?

What is the most accurate way to convert CIELab color values to CMYK? I have been looking at the ColorMine library , and it appears to first convert from CIELab to RGB, followed by conversions from RGB to CMY, and from CMY to CMYK. Is this the best or correct method?

Here is an example of the conversion from RGB to CMY. It seems very primitive to me, and I think it assumes that the white point for RGB and CMY are the same, which I am not sure about.

    internal static void ToColorSpace(IRgb color, ICmy item)
    {
        item.C = 1 - (color.R / 255.0);
        item.M = 1 - (color.G / 255.0);
        item.Y = 1 - (color.B / 255.0);
    }

There isn't a single accurate way to convert between Lab, CMYK or RGB, because CMYK and RGB are both device dependant.

Essentially, an accurate conversion requires you to first have the specifications of the device upon which the CMYK color will be displayed. Only then can you calculate the exact CMYK color that will, on that specific device, match your Lab color. Without device data, you can only generate an approximation.

That's where ICC profiles come in. ICC Profiles for devices that support CMYK will contain tables to be used for conversion between Lab and CMYK.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM