# IColorData

interface IColorData

Interface describing colorimetry data

#### Inheritors

ColorData

## Types

ColorDifferenceType
Link copied to clipboard
enum ColorDifferenceType : Enum<IColorData.ColorDifferenceType>

Enum describing the available color difference (delta E) equations.

ColorType
Link copied to clipboard
enum ColorType : Enum<IColorData.ColorType>

Enum to describe the base color data types available for IColorData objects. Values for each of these types can be freely converted to each other without loss of color data.

## Properties

colorInt
Link copied to clipboard
@get:ColorInt
open val colorInt: Int

sRGB value for this color (as a ColorInt).

hexCode
Link copied to clipboard
open val hexCode: String

sRGB value for this color as a HEX string (#RRGGBB)

mode
Link copied to clipboard
abstract val mode: ScanMode

Scan mode for this value (one of ScanMode.M0, ScanMode.M1, or ScanMode.M2).

reference
Link copied to clipboard
abstract val reference: ReferenceWhite

Reference white point for this color value.

rgbValue
Link copied to clipboard
abstract val rgbValue: IntArray

sRGB value for this color.

type
Link copied to clipboard
abstract val type: IColorData.ColorType

Type of color data stored in the value field.

value
Link copied to clipboard
abstract val value: DoubleArray

Color value (3 coordinates) in the format specified by mode.

## Functions

compareTo
Link copied to clipboard
abstract fun compareTo(other: IColorData, type: IColorData.ColorDifferenceType = ColorDifferenceType.CIE2000): Double

Calculate delta E between this color and another. The colors must share the same reference white point (reference)

convertTo
Link copied to clipboard
abstract fun convertTo(type: IColorData.ColorType): IColorData

Convert this color value to another ColorType.