def RGBtoYCC(R, G, B):
    """ convert RGB to YCC color
    The Kodak* PhotoYCC* was developed for encoding Photo CD* image data.
    This model comprises luminance (Y) and two color difference, or chrominance (C1, C2) components.
    The PhotoYCC is optimized for the color photographic material,
    and provides a color gamut that is greater than the one that can currently be displayed.
    Warning: Converting RGB to YCC then back doesn't necessarily give the same result
    :param R: red value (0;255)
    :param G: green value (0;255)
    :param B: blue value (0;255)
    :return: YCC tuple (0;1) """
    rgb = [i / 255.0 for i in (R, G, B)]

    Y = (0.213 * rgb[0]) + (0.419 * rgb[1]) + (0.081 * rgb[2])
    C1 = (-0.131 * rgb[0]) - (0.256 * rgb[1]) + (0.387 * rgb[2]) + 0.612
    C2 = (0.373 * rgb[0]) - (0.312 * rgb[1]) - (0.061 * rgb[2]) + 0.537

    return Y, C1, C2