Function rgbToYuv

  • Converts RGB color values to YUV color space.

    Parameters

    • rgb: RGB

      The RGB color to convert.

    Returns YUV

    The color in YUV color space.

    If the input is not a valid RGB object or if RGB values are out of range.