Top Level Namespace
Defined in:
Method Summary
-
color(r : Number, g : Number, b : Number, a : Number = Glint::Color::MAXIMUM_VALUE)
Creates a
Color
. -
color(c : Raylib::Color)
Creates a
Glint::Color
from aRaylib::Color
. -
color(hex : String)
Creates a
Color
from a hex string. -
color(value : Number)
Creates a
Color
from a value. -
color(values : Tuple(Int32, Int32, Int32) | Tuple(Int32, Int32, Int32, Int32))
Creates a
Color
from a tuple. -
p(x, y)
Creates a
Glint::Position
from x and y coordinates. -
p(v : Glint::Vector2)
Creates a
Position
from aGlint::Vector2
. -
rect(r : Raylib::Rectangle)
Creates a
Rect
from aRaylib::Rectangle
. -
rect(x : Number = 0, y : Number = 0, width : Number = 0, height : Number = 0)
Creates a
Rect
from x and y coordinates and a width and a height. -
rect(x : Number = 0, y : Number = 0, size : Dimension = Dimension.new(0, 0))
Creates a
Rect
from x and y coordinates and a size. -
rect(r : Rect)
Creates a
Rect
from anotherRect
. -
rect(position : Position = Position.new(0, 0), width : Number = 0, height : Number = 0)
Creates a
Rect
from a position, a width and a height. -
rect(position : Position = Position.new(0, 0), size : Dimension = Dimension.new(0, 0))
Creates a
Rect
from a position and a size. -
size(x, y)
Creates a
Dimension
from x and y coordinates. -
size(v : Glint::Vector2)
Creates a
Dimension
from aVector2
. -
vec(v : Raylib::Vector2)
Creates a
Glint::Vector2
from aRaylib::Vector2
. -
vec(x : Number = 0, y : Number = 0)
Creates a
Glint::Vector2
from x/y coordinates. -
vec(v : Glint::Vector2)
Creates a
Glint::Vector2
from anotherGlint::Vector2
. -
vel(x : Number, y : Number)
Creates a new
Glint::Velocity
x/y coordinates. -
vel(v : Glint::Vector2)
Creates a new
Glint::Velocity
from aGlint::Vector2
.
Method Detail
Creates a Color
.
# Example:
red = color(255, 0, 0)
Creates a Glint::Color
from a Raylib::Color
.
# Example:
red1 = color(Raylib::Color.new r: 255, g: 0, b: 0, a: 255)
red2 = color(Raylib::RED)
Creates a Color
from a hex string.
# Example:
red1 = color("#ff0000")
red2 = color("#FF0000FF")
red3 = color("FF0000")
Creates a Color
from a value.
# Example:
red = color(0xFF000000)
Creates a Color
from a tuple.
# Example:
red = color({255, 0, 0})
Creates a Rect
from x and y coordinates and a width and a height.
# Example
my_rect = rect(250, 350, Dimension.new(100, 200))
Creates a Rect
from x and y coordinates and a size.
# Example
my_rect = rect(250, 350, Dimension.new(100, 200))
Creates a Rect
from another Rect
.
# Example
my_rect = rect(250, 350, Dimension.new(100, 200))
other_rect = rect(my_rect)
Creates a Rect
from a position, a width and a height.
# Example
my_rect = rect(Position.new(250, 350), 100, 200)
Creates a Rect
from a position and a size.
# Example
my_rect = rect(Position.new(250, 350), Dimension.new(100, 200))
Creates a Glint::Vector2
from x/y coordinates.