Table of Contents

TScRGBColor Structure

Implements a simple representation of a color in scRGB colorspace. Components are doubles going from 0 to 1.

Syntax

Namespace: FlexCel.Core

public struct TScRGBColor

Constructors

Methods

Name Description
RGBtoSRGB Converts a RGB value to sRGB using a gamma of 2.2
SRGBtoRGB Converts a sRGB value to RGB using a gamma of 2.2
Equals Returns true if both colors are the same.
GetHashCode Returns a hashcode for the color.
CompareTo Returns -1 if obj is more than color, 0 if both colors are the same, and 1 if obj is less than color.

Operators

Name Description
Implicit Conversion Overloaded
Implicit conversion from TUIColor to TScRGBColor
Implicit conversion from TScRGBColor to TUIColor
Implicit conversion from Color to TScRGBColor
Implicit conversion from TScRGBColor to Color
Equality Returns true if both colors are equal.
Inequality Returns true if both colors do not have the same value.
GreaterThan Returns true if o1 is bigger than o2.
LessThan Returns true if o1 is less than o2.

Properties

Name Description
ScR ScRed component. (between 0 and 1)
ScG ScGreen component. (between 0 and 1)
ScB ScBlue component. (between 0 and 1)
R Red component in the RGB space. (0-255)
G Green component in the RGB space. (0-255)
B Blue component in the RGB space. (0-255)
Empty Returns an empty color.