Calculates the 'distance' of two HSB colors
Namespace:
Eto.Drawing
Assembly:
Eto (in Eto.dll) Version: 2.5.3-dev
Syntax public static float Distance(
ColorHSB value1,
ColorHSB value2
)
Public Shared Function Distance (
value1 As ColorHSB,
value2 As ColorHSB
) As Single
static member Distance :
value1 : ColorHSB *
value2 : ColorHSB -> float32
Parameters
- value1
- Type: Eto.DrawingColorHSB
First color to compare - value2
- Type: Eto.DrawingColorHSB
Second color to compare
Return Value
Type:
SingleThe overall distance/difference between the two colours. A lower value indicates a closer match
Remarks
This is useful for comparing two different color values to determine if they are similar.
Typically though,
Distance(ColorHSL, ColorHSL) gives the best result instead of this method.
See Also