|
ViewDesignEngine
3.1.0
高性能 CAD 计算几何引擎
|
统一谓词接口 — 编译时选择 GMP 或自适应双精度后端 更多...
#include <predicates.h>
Public 类型 | |
| using | Backend = exact::AdaptiveDouble |
| 使用自适应双精度算术(Shewchuk 算法,默认) 更多... | |
静态 Public 成员函数 | |
| static exact::Orientation | orient_2d (const Point2D &a, const Point2D &b, const Point2D &c) |
| 二维定向测试 更多... | |
| static exact::Orientation | orient_3d (const Point3D &a, const Point3D &b, const Point3D &c, const Point3D &d) |
| 三维定向测试 更多... | |
| static exact::CircleTest | in_circle (const Point2D &a, const Point2D &b, const Point2D &c, const Point2D &d) |
| 圆内测试 更多... | |
统一谓词接口 — 编译时选择 GMP 或自适应双精度后端
根据 VDE_USE_GMP 宏自动选择 GmpExact 或 AdaptiveDouble 作为后端。 上层代码只需使用 Predicates,无需关心具体实现。
在文件 predicates.h 第 17 行定义.
| using vde::foundation::Predicates::Backend = exact::AdaptiveDouble |
使用自适应双精度算术(Shewchuk 算法,默认)
在文件 predicates.h 第 23 行定义.
|
inlinestatic |
圆内测试
| a,b,c | 三角形三顶点 |
| d | 测试点 |
在文件 predicates.h 第 49 行定义.
引用了 vde::foundation::in_circle().
被这些函数引用 vde::foundation::in_circle().
|
inlinestatic |
二维定向测试
| a,b,c | 三点 |
在文件 predicates.h 第 31 行定义.
引用了 vde::foundation::exact::orient_2d().
被这些函数引用 vde::foundation::orient().
|
inlinestatic |
三维定向测试
| a,b,c,d | 四点 |
在文件 predicates.h 第 39 行定义.
引用了 vde::foundation::exact::orient_3d().
被这些函数引用 vde::foundation::orient().