ColorRGBA
Represents a sRGBA (Red, Green, Blue, Alpha) color with double precision floating point channel.
Namespace: Rhino.Display
Assembly: RhinoCommon (in RhinoCommon.dll)
Syntax
[SerializableAttribute]public struct ColorRGBA : ISerializable, IFormattable, IComparable, IComparable<ColorRGBA>, IEquatable<ColorRGBA>, IEpsilonComparable<ColorRGBA>
The ColorRGBA type exposes the following members.
Constructors
Name
Description
Public Method
ColorRGBA(Color)
Constructs a new instance of ColorRGBA that is equivalent to an ARGB color.
Public Method
ColorRGBA(ColorRGBA)
Initializes a new instance of the ColorRGBA class
Public Method
ColorRGBA(Int32)
Constructs a new instance of ColorRGBA that is equivalent to an ARGB color.
Public Method
ColorRGBA(ColorRGBA, Double)
Initializes a new instance of the ColorRGBA class
Public Method
ColorRGBA(Double, Double, Double)
Initializes a new instance of the ColorRGBA class
Public Method
ColorRGBA(Double, Double, Double, Double)
Initializes a new instance of the ColorRGBA class
Properties
Name
Description
Public Property
A
Gets or sets the alpha channel value. Alpha channels are limited to a 0~1 range.
Public Property
B
Gets or sets the blue channel value. Blue channels are limited to a 0~1 range.
Public Property
Static Member
Black
Public Property
Static Member
Blue
Public Property
G
Gets or sets the green channel value. Green channels are limited to a 0~1 range.
Public Property
Static Member
Green
Public Property
R
Gets or sets the red channel value. Red channels are limited to a 0~1 range.
Public Property
Static Member
Red
Public Property
Static Member
White
Methods
Name
Description
Public Method
Static Member
ApplyGamma
Public Method
BlendTo
Public Method
CompareTo
Compares this ColorRGBA with another ColorRGBA.
Channels evaluation priority is first A, then R, then G, then B.
Public Method
Static Member
CreateFromArgb(Byte, Byte, Byte)
Constructs a RGBA color from the specified 8-bit components (red, green, and blue) values. The alpha value is implicitly 1.0 (fully opaque).
Public Method
Static Member
CreateFromArgb(Byte, Byte, Byte, Byte)
Constructs a RGBA color from the four ARGB components (alpha, red, green, and blue) values.
Public Method
Static Member
CreateFromCMYK
Create the nearest RGBA equivalent of a CMYK color.
Public Method
Static Member
CreateFromHSL
Constructs the nearest RGBA equivalent of an HSV color.
Public Method
Static Member
CreateFromHSV
Constructs the nearest RGBA equivalent of an HSL color.
Public Method
Static Member
CreateFromLAB
Create the nearest RGBA equivalent of a LAB color.
Public Method
Static Member
CreateFromLCH
Create the nearest RGBA equivalent of a LCH color.
Public Method
Static Member
CreateFromXYZ
Create the nearest RGBA equivalent of an XYZ color.
Public Method
EpsilonEquals
Check that all values in other are within epsilon of the values in this
Public Method
Equals(ColorRGBA)
Determines whether the specified ColorRGBA has the same values as the present color.
Public Method
Equals(Object)
(Overrides ValueType.Equals(Object).)
Public Method
GetHashCode
(Overrides ValueType.GetHashCode..)
Public Method
GetType
Gets the Type of the current instance.
(Inherited from Object.)
Public Method
ToArgb
Converts this color to a 32-bit ARGB value.
Public Method
ToString.
(Overrides ValueType.ToString..)
Public Method
ToString(String, IFormatProvider)
Operators
Name
Description
Public Operator
Static Member
Equality
Public Operator
Static Member
.(ColorRGBA to Color)
Converts a ColorRGBA in a Color.
Public Operator
Static Member
.(Color to ColorRGBA)
Public Operator
Static Member
Inequality