Get the bottom edge Y coordinate 获取底边Y坐标
Get the bottom-left corner as a vector 获取左下角作为向量
Get the bottom-right corner as a vector 获取右下角作为向量
Get the center point of the rectangle 获取矩形的中心点
Get the left edge X coordinate 获取左边缘X坐标
Get the right edge X coordinate 获取右边缘X坐标
Get the top edge Y coordinate 获取顶边Y坐标
Get the top-left corner as a vector 获取左上角作为向量
Get the top-right corner as a vector 获取右上角作为向量
Get the area of the rectangle 获取矩形的面积
Create a copy of this rectangle 创建此矩形的副本
Check if a point is inside this rectangle (inclusive of edges) 检查点是否在此矩形内(包含边缘)
Check if this rectangle equals another rectangle 检查此矩形是否等于另一个矩形
Check if this rectangle intersects with another rectangle 检查此矩形是否与另一个矩形相交
Check if the rectangle is empty (zero or negative area) 检查矩形是否为空(零或负面积)
Get the perimeter of the rectangle 获取矩形的周长
Convert to a regular number array [x, y, width, height] 转换为普通数字数组 [x, y, width, height]
Convert to string representation 转换为字符串表示
Static
centeredCreate a rectangle centered at the given point 创建以给定点为中心的矩形
Static
fromCreate a rectangle from an array [x, y, width, height] 从数组创建矩形 [x, y, width, height]
Static
fromCreate a rectangle from two corner points 从两个角点创建矩形
Rectangle using fixed-point arithmetic for deterministic calculations 使用定点算术的矩形,用于确定性计算