Rectangle
Rectangle
- half_size : glam::Vec2
Description
A rectangle primitive, which is like a square, except that the width and height can be different
Functions
Function | Summary |
---|---|
clone(_self) | No Documentation 🚧 |
closest_point(_self, point) | Finds the point on the rectangle that is closest to the given `point`. If the point is outside the |
eq(_self, other) | No Documentation 🚧 |
from_corners(point1, point2) | Create a new `Rectangle` from two corner points |
from_length(length) | Create a `Rectangle` from a single length. The resulting `Rectangle` will be the same size in ever |
from_size(size) | Create a new `Rectangle` from a given full size |
new(width, height) | Create a new `Rectangle` from a full width and height |
size(_self) | Get the size of the rectangle |