OpenMesh有它的VectorT类,我认为它用于执行各种位置矢量运算(加/减、内积和外积等)。有关于如何实际使用它的例子吗?我会特别感兴趣
mesh.point(vhandle),但是它返回一个Point()类型。编辑:显然是某种VectorT本身,因为VectorT成员函数也工作在Point对象上。
发布于 2020-10-30 07:36:20
使用OpenMesh本机点类型进行数学操作的示例:
OpenMesh::Vec3f myVec = OpenMesh::Vec3f(0, 0, 0);float distance = (point1 - point2).norm();也提供:l1_norm(),l8_norm(),sqrnorm()Point interpolated_point = (1 - a) * point1 + a * point2;Vec3f crossProduct = vec1 % vec2;只为Vec3定义(正如您提到的Point)Vec3f dotProduct = vec1 | vec2;https://stackoverflow.com/questions/64574464
复制相似问题