Megadocs 0.0.1
All of megapop's internal libraries
Megapop.MegaCore.ColorUtil Class Reference

Static Public Member Functions

static Color FromVector3 (Vector3 v, float alpha=1)
 
static Color FromVector4 (Vector4 v)
 
static Color FromRgb (int rgb, float alpha=1f)
 
static Color FromArgb (int argb)
 
static Color FromRgb (byte[] bytes)
 
static Color FromArgb (byte[] bytes)
 
static Color FromCmyk (float c, float m, float y, float k, float alpha=1)
 
static Color FromHex (string hex)
 
static Color FromHtml (string html)
 
static Color FromHash (byte[] bytes)
 
static Color FromHash (string input)
 
static Color FromHash (int input)
 
static Color RandomRgb (float alpha=1f)
 
static bool Approximately (Color c1, Color c2)
 
static Color MoveTowards (Color current, Color target, float maxDelta)
 
static Color MoveTowards (Color current, Color target, Vector4 maxDelta)
 

Static Public Attributes

static readonly Color Red = new Color32(255, 0, 0, 255)
 
static readonly Color Orange = new Color32(255, 127, 0, 255)
 
static readonly Color Yellow = new Color32(255, 255, 0, 255)
 
static readonly Color Green = new Color32(0, 255, 0, 255)
 
static readonly Color GuppieGreen = new Color32(0, 255, 127, 255)
 
static readonly Color Cyan = new Color32(0, 255, 255, 255)
 
static readonly Color BrandeisBlue = new Color32(0, 127, 255, 255)
 
static readonly Color Blue = new Color32(0, 0, 255, 255)
 
static readonly Color Purple = new Color32(127, 0, 255, 255)
 
static readonly Color Magenta = new Color32(255, 0, 255, 255)
 
static readonly Color Rose = new Color32(255, 0, 127, 255)
 
static readonly Color Black = new Color32(0, 0, 0, 255)
 
static readonly Color DarkGray = new Color32(64, 64, 64, 255)
 
static readonly Color Gray = new Color32(127, 127, 127, 255)
 
static readonly Color LightGray = new Color32(191, 191, 191, 255)
 
static readonly Color White = new Color32(255, 255, 255, 255)
 
static readonly Color ClearBlack = new Color32(0, 0, 0, 0)
 
static readonly Color ClearWhite = new Color32(1, 1, 1, 0)
 

Member Function Documentation

◆ Approximately()

static bool Megapop.MegaCore.ColorUtil.Approximately ( Color  c1,
Color  c2 
)
inlinestatic

◆ FromArgb() [1/2]

static Color Megapop.MegaCore.ColorUtil.FromArgb ( byte[]  bytes)
static

◆ FromArgb() [2/2]

static Color Megapop.MegaCore.ColorUtil.FromArgb ( int  argb)
inlinestatic

◆ FromCmyk()

static Color Megapop.MegaCore.ColorUtil.FromCmyk ( float  c,
float  m,
float  y,
float  k,
float  alpha = 1 
)
inlinestatic

◆ FromHash() [1/3]

static Color Megapop.MegaCore.ColorUtil.FromHash ( byte[]  bytes)
inlinestatic

◆ FromHash() [2/3]

static Color Megapop.MegaCore.ColorUtil.FromHash ( int  input)
static

◆ FromHash() [3/3]

static Color Megapop.MegaCore.ColorUtil.FromHash ( string  input)
static

◆ FromHex()

static Color Megapop.MegaCore.ColorUtil.FromHex ( string  hex)
inlinestatic

◆ FromHtml()

static Color Megapop.MegaCore.ColorUtil.FromHtml ( string  html)
inlinestatic

◆ FromRgb() [1/2]

static Color Megapop.MegaCore.ColorUtil.FromRgb ( byte[]  bytes)
static

◆ FromRgb() [2/2]

static Color Megapop.MegaCore.ColorUtil.FromRgb ( int  rgb,
float  alpha = 1f 
)
inlinestatic

◆ FromVector3()

static Color Megapop.MegaCore.ColorUtil.FromVector3 ( Vector3  v,
float  alpha = 1 
)
static

◆ FromVector4()

static Color Megapop.MegaCore.ColorUtil.FromVector4 ( Vector4  v)
static

◆ MoveTowards() [1/2]

static Color Megapop.MegaCore.ColorUtil.MoveTowards ( Color  current,
Color  target,
float  maxDelta 
)
inlinestatic

◆ MoveTowards() [2/2]

static Color Megapop.MegaCore.ColorUtil.MoveTowards ( Color  current,
Color  target,
Vector4  maxDelta 
)
inlinestatic

◆ RandomRgb()

static Color Megapop.MegaCore.ColorUtil.RandomRgb ( float  alpha = 1f)
static

Member Data Documentation

◆ Black

readonly Color Megapop.MegaCore.ColorUtil.Black = new Color32(0, 0, 0, 255)
static

◆ Blue

readonly Color Megapop.MegaCore.ColorUtil.Blue = new Color32(0, 0, 255, 255)
static

◆ BrandeisBlue

readonly Color Megapop.MegaCore.ColorUtil.BrandeisBlue = new Color32(0, 127, 255, 255)
static

◆ ClearBlack

readonly Color Megapop.MegaCore.ColorUtil.ClearBlack = new Color32(0, 0, 0, 0)
static

◆ ClearWhite

readonly Color Megapop.MegaCore.ColorUtil.ClearWhite = new Color32(1, 1, 1, 0)
static

◆ Cyan

readonly Color Megapop.MegaCore.ColorUtil.Cyan = new Color32(0, 255, 255, 255)
static

◆ DarkGray

readonly Color Megapop.MegaCore.ColorUtil.DarkGray = new Color32(64, 64, 64, 255)
static

◆ Gray

readonly Color Megapop.MegaCore.ColorUtil.Gray = new Color32(127, 127, 127, 255)
static

◆ Green

readonly Color Megapop.MegaCore.ColorUtil.Green = new Color32(0, 255, 0, 255)
static

◆ GuppieGreen

readonly Color Megapop.MegaCore.ColorUtil.GuppieGreen = new Color32(0, 255, 127, 255)
static

◆ LightGray

readonly Color Megapop.MegaCore.ColorUtil.LightGray = new Color32(191, 191, 191, 255)
static

◆ Magenta

readonly Color Megapop.MegaCore.ColorUtil.Magenta = new Color32(255, 0, 255, 255)
static

◆ Orange

readonly Color Megapop.MegaCore.ColorUtil.Orange = new Color32(255, 127, 0, 255)
static

◆ Purple

readonly Color Megapop.MegaCore.ColorUtil.Purple = new Color32(127, 0, 255, 255)
static

◆ Red

readonly Color Megapop.MegaCore.ColorUtil.Red = new Color32(255, 0, 0, 255)
static

◆ Rose

readonly Color Megapop.MegaCore.ColorUtil.Rose = new Color32(255, 0, 127, 255)
static

◆ White

readonly Color Megapop.MegaCore.ColorUtil.White = new Color32(255, 255, 255, 255)
static

◆ Yellow

readonly Color Megapop.MegaCore.ColorUtil.Yellow = new Color32(255, 255, 0, 255)
static

The documentation for this class was generated from the following file: