RGBColor
public struct RGBColor : ColorType
Color Type of RGB Color
-
Red
Declaration
Swift
public let red: Float
-
Green
Declaration
Swift
public let green: Float
-
Blue
Declaration
Swift
public let blue: Float
-
Amount of Alpha
0.0 to 1.0
Declaration
Swift
public let alpha: Float
-
Undocumented
Declaration
Swift
public init(r: Float, g: Float, b: Float, a: Float)
-
Encodes this value into the given encoder.
If the value fails to encode anything,
encoder
will encode an empty keyed container in its place.This function throws an error if any values are invalid for the given encoder’s format.
Declaration
Swift
public func encode(to encoder: Encoder) throws
Parameters
encoder
The encoder to write data to.