Table of Contents

Class ColorExtensions

Namespace
Stride.Core.Mathematics
Assembly
Stride.Core.Mathematics.dll

A class containing extension methods for processing colors.

public static class ColorExtensions
Inheritance
ColorExtensions

Methods

CanConvertStringToRgba(string)

Indicates if the given string can be converted to an uint RGBA value using StringToRgba(string).

public static bool CanConvertStringToRgba(string stringColor)

Parameters

stringColor string

The string to convert.

Returns

bool

True if the string can be converted, false otherwise.

RgbToString(int)

Converts the given RGB value to a string.

public static string RgbToString(int value)

Parameters

value int

The RGB value to convert.

Returns

string

The converted string.

RgbaToString(int)

Converts the given RGBA value to a string.

public static string RgbaToString(int value)

Parameters

value int

The RGBA value to convert.

Returns

string

The converted string.

StringToRgba(string)

Converts the given string to an uint RGBA value.

public static uint StringToRgba(string stringColor)

Parameters

stringColor string

The string to convert.

Returns

uint

The converted RGBA value.