二维矩形, 单精度.
More...
#include <Rect2.h>
◆ Rect2() [1/2]
Rect2::Rect2 |
( |
const Point2 & |
origin, |
|
|
const Size2 & |
size |
|
) |
| |
构造函数.
- Parameters
-
origin | 矩形坐标, 左上角. |
size | 矩形大小. |
◆ Rect2() [2/2]
Rect2::Rect2 |
( |
float |
x, |
|
|
float |
y, |
|
|
float |
width, |
|
|
float |
height |
|
) |
| |
构造函数.
- Parameters
-
x | x坐标. |
y | y坐标. |
width | 宽度. |
height | 高度. |
◆ intersectsPoint()
bool Rect2::intersectsPoint |
( |
const Point2 & |
point | ) |
const |
检测是否与二维点发生相交.
- Parameters
-
- Returns
- 相交则返回 true, 否则返回 false.
◆ intersectsRect()
bool Rect2::intersectsRect |
( |
const Rect2 & |
rect | ) |
const |
检测是否与二维矩形发生相交.
- Parameters
-
- Returns
- 相交则返回 true, 否则返回 false.
The documentation for this class was generated from the following files:
- Source/Clem/Core/Math/Rect2.h
- Source/Clem/Core/Math/Rect2.cpp