Crono::Color
Inherits Struct / Value / Object
Constants
BLACK = SDL::Color[0]
BLUE = SDL::Color[0, 0, 255]
CYAN = SDL::Color[0, 255, 255]
DODGER = SDL::Color[0, 171, 255]
GRAY = SDL::Color[128]
GREEN = SDL::Color[0, 255, 0]
LIME = SDL::Color[171, 255, 0]
MAGENTA = SDL::Color[255, 0, 255]
ORANGE = SDL::Color[255, 171, 0]
PINK = SDL::Color[255, 0, 171]
PURPLE = SDL::Color[171, 0, 171]
RED = SDL::Color[255, 0, 0]
SPRING = SDL::Color[0, 255, 171]
WHITE = SDL::Color[255]
R, G, B, A
YELLOW = SDL::Color[255, 255, 0]
Constructors
new
Class methods
darken(values : RGBA, percent : Int32)
Returns RGBA with all non-zero values lowered by percent.
Does not change transparency
lighten(values : RGBA, percent : Int32)
rand
to_hex(values : RGB)
to_hex(values : RGBA)
Instance methods
initialize
Macros
[](r, g, b, a = 255)