类 | |
class | Cube |
struct | IntersectInfo |
struct | Mesh |
struct | Rect3 |
struct | Vec3 |
类型定义 | |
using | Fun3s = std::function<double(Vec3 const &)> |
using | Fun3v = std::function<Vec3(Vec3 const &)> |
using | Triangle = std::array<int, 3> |
函数 | |
Mesh | MarchCube (Fun3s const &sdf, Rect3 const &domain) |
使用 Marching Cube 从给定的有向距离函数重建三角形网格。 | |
Mesh | MarchCube (Fun3s const &sdf, Rect3 const &domain, Vec3 const &cubeSize, double isoLevel=0, Fun3v sdfGrad=nullptr) |
使用 Marching Cube 从给定的有向距离函数重建三角形网格。 | |
void | Triangulate (IntersectInfo const &intersect, Fun3v const &grad, Mesh &mesh) |
给定一个网格立方体和一个等值面,计算出在立方体中表示等值面的三角形(最多5个)。 | |
using MeshReconstruction::Fun3s = std::function<double(Vec3 const &)> |
在文件 DataStructs.h 第 75 行定义.
using MeshReconstruction::Fun3v = std::function<Vec3(Vec3 const &)> |
在文件 DataStructs.h 第 78 行定义.
using MeshReconstruction::Triangle = std::array<int, 3> |
在文件 DataStructs.h 第 60 行定义.
使用 Marching Cube 从给定的有向距离函数重建三角形网格。
sdf | 有符号距离函数。 |
域 | 重建域。 |
在文件 MeshReconstruction.h 第 55 行定义.
引用了 MarchCube() , 以及 MeshReconstruction::Rect3::size.
被这些函数引用 MarchCube().
Mesh MeshReconstruction::MarchCube | ( | Fun3s const & | sdf, |
Rect3 const & | domain, | ||
Vec3 const & | cubeSize, | ||
double | isoLevel = 0, | ||
Fun3v | sdfGrad = nullptr ) |
使用 Marching Cube 从给定的有向距离函数重建三角形网格。
sdf | 有符号距离函数。 |
域 | 重建域。 |
cubeSize | 行进立方体的大小。立方体越小,生成的网格分辨率越高。 |
应对其进行三角剖分的 | SDF 的 isoLevel Level 集。更改此值将移动重建的表面。 |
SDF | 的 sdfGrad 梯度,可生成重建网格的顶点法线。如果未提供任何参数,则使用数值近似值。 |
在文件 MeshReconstruction.h 第 63 行定义.
引用了 MeshReconstruction::Cube::Intersect(), MeshReconstruction::Rect3::min, min(), MeshReconstruction::Vec3::Norm(), MeshReconstruction::Rect3::size, Triangulate(), MeshReconstruction::Vec3::x, MeshReconstruction::Vec3::y , 以及 MeshReconstruction::Vec3::z.
void MeshReconstruction::Triangulate | ( | IntersectInfo const & | intersect, |
Fun3v const & | grad, | ||
Mesh & | mesh ) |
给定一个网格立方体和一个等值面,计算出在立方体中表示等值面的三角形(最多5个)。
在文件 Triangulation.h 第 282 行定义.
引用了 MeshReconstruction::IntersectInfo::edgeVertIndices, MeshReconstruction::IntersectInfo::signConfig, MeshReconstruction::Mesh::triangles, MeshReconstruction::Mesh::vertexNormals , 以及 MeshReconstruction::Mesh::vertices.
被这些函数引用 MarchCube().