docs: update math API docs
This commit is contained in:
30
docs/api/math/obb/get-max.md
Normal file
30
docs/api/math/obb/get-max.md
Normal file
@@ -0,0 +1,30 @@
|
||||
# OBB::GetMax
|
||||
|
||||
```cpp
|
||||
Vector3 GetMax() const;
|
||||
```
|
||||
|
||||
获取 OBB 包围盒在局部坐标系下的最大顶点。该点是中心点加上半长向量计算得出。
|
||||
|
||||
**参数:** 无
|
||||
|
||||
**返回:** 包围盒的最大顶点
|
||||
|
||||
**异常:** 无
|
||||
|
||||
**线程安全:** ✅
|
||||
|
||||
**复杂度:** O(1)
|
||||
|
||||
**示例:**
|
||||
|
||||
```cpp
|
||||
#include "AABB.h"
|
||||
#include "Vector3.h"
|
||||
|
||||
using namespace XCEngine::Math;
|
||||
|
||||
OBB obb(Vector3(0.0f, 0.0f, 0.0f), Vector3(1.0f, 0.5f, 1.0f));
|
||||
|
||||
Vector3 maxPoint = obb.GetMax();
|
||||
```
|
||||
Reference in New Issue
Block a user