struct Prism::ColorUInt8

Defined in:

prism/texture/color.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(red : UInt8, green : UInt8, blue : UInt8, alpha : UInt8) #

[View source]
def self.new(red : UInt8, green : UInt8, blue : UInt8) #

[View source]

Instance Method Detail

def alpha : UInt8 #

[View source]
def alpha=(alpha : UInt8) #

[View source]
def black? #

Checks if the color is black


[View source]
def blue : UInt8 #

[View source]
def blue=(blue : UInt8) #

[View source]
def green : UInt8 #

[View source]
def green=(green : UInt8) #

[View source]
def red : UInt8 #

[View source]
def red=(red : UInt8) #

[View source]
def to_s #
Description copied from class Object

Returns a nicely readable and concise string representation of this object, typically intended for users.

This method should usually not be overridden. It delegates to #to_s(IO) which can be overridden for custom implementations.

Also see #inspect.


[View source]
def transparent? #

Checks if the color has transparency


[View source]
def white? #

Checks if the color is white


[View source]