HsvColor Structure

Defines a color using the hue/saturation/value (HSV) model. This uses a cylindrical-coordinate representation of a color.

Definition

Namespace: Avalonia.Media
Assembly: Avalonia.Base (in Avalonia.Base.dll) Version: 11.3.999
public readonly struct HsvColor : IEquatable<HsvColor>
Inheritance
Object    ValueType    HsvColor
Implements
IEquatableHsvColor

Properties

A Gets the Alpha (transparency) component in the range from 0..1 (percentage).
H Gets the Hue component in the range from 0..360 (degrees). This is the color's location, in degrees, on a color wheel/circle from 0 to 360. Note that 360 is equivalent to 0 and will be adjusted automatically.
S Gets the Saturation component in the range from 0..1 (percentage).
V Gets the Value (or Brightness/Intensity) component in the range from 0..1 (percentage).

Methods

Equals(HsvColor)Indicates whether the current object is equal to another object of the same type.
Equals(Object)Indicates whether this instance and a specified object are equal.
(Overrides ValueTypeEquals(Object))
FromAhsv(Double, Double, Double, Double) Creates a new HsvColor from individual color component values.
FromHsv(Double, Double, Double) Creates a new HsvColor from individual color component values.
GetHashCode Gets a hashcode for this object. Hashcode is not guaranteed to be unique.
(Overrides ValueTypeGetHashCode)
GetTypeGets the Type of the current instance.
(Inherited from Object)
Parse(String) Parses an HSV color string.
ToHsl Returns the HSL color model equivalent of this HSV color.
ToHsl(Double, Double, Double, Double) Converts the given HSVA color component values to their HSL color equivalent.
ToRgb Returns the RGB color model equivalent of this HSV color.
ToRgb(Double, Double, Double, Double) Converts the given HSVA color component values to their RGB color equivalent.
ToStringReturns the fully qualified type name of this instance.
(Overrides ValueTypeToString)
TryParse(String, HsvColor) Parses an HSV color string.

Operators

Equality(HsvColor, HsvColor) Indicates whether the values of two specified HsvColor objects are equal.
(HsvColor to Color) Explicit conversion from an HsvColor to a Color.
Inequality(HsvColor, HsvColor) Indicates whether the values of two specified HsvColor objects are not equal.

See Also