![]() |
ImFusion SDK 4.3
|
Miscellaneous mesh processing functions. More...
Miscellaneous mesh processing functions.
Enumerations | |
| enum class | FillType { None = 0 , Bottom , Top } |
| Filling type for the label map computation. More... | |
Functions | |
| bool | invertNormals (Mesh &mesh) |
| Invert the vertex normals of the Mesh. Returns false if mesh has no vertex normals. | |
| void | burnInTransformation (Mesh &mesh, const mat4 &transformation) |
| Applies the transformation to all mesh vertices. | |
| std::unique_ptr< TypedImage< unsigned char > > | computeLabelMap (Mesh &mesh, const vec3 &resolution, unsigned int margin=10, unsigned int dir=2, FillType fill=FillType::None, vec3i *targetDim=nullptr) |
| Compute label map volume from the mesh, representing the inside of a closed surface. | |
| void | erodeBoundary (Mesh &mesh, int layers) |
| Removes mesh boundary faces (faces which have at least one boundary edge) | |
| bool | transferMeshFaceLabels (const Mesh &meshSrc, Mesh &meshDst) |
| Transfer face labels from source mesh to destination mesh by propagating the label of its nearest neighbor. | |
|
strong |
| void burnInTransformation | ( | Mesh & | mesh, |
| const mat4 & | transformation ) |
Applies the transformation to all mesh vertices.
Transformation is also applied to vertex normals, halfedge normals and face normals if present
| [in,out] | mesh | Mesh |
| [in] | transformation | The transformation matrix |
| std::unique_ptr< TypedImage< unsigned char > > computeLabelMap | ( | Mesh & | mesh, |
| const vec3 & | resolution, | ||
| unsigned int | margin = 10, | ||
| unsigned int | dir = 2, | ||
| FillType | fill = FillType::None, | ||
| vec3i * | targetDim = nullptr ) |
Compute label map volume from the mesh, representing the inside of a closed surface.
| [in,out] | mesh | Mesh |
| [in] | resolution | Resolution of a single voxel |
| [in] | margin | Additional voxels added at the volume boundaries |
| [in] | dir | Axis along which ray-mesh intersection should be performed (0 is x-axis, 1 is y-axis, 2 is z-axis) |
| [in] | fill | Specifies whether the label map should be manually closed in case of an open mesh |
| [in] | targetDim | Optional target dimension of the computed volume. If not provided, the dimension will be computed as [mesh extent] * [resolution] + [margin] |
| void erodeBoundary | ( | Mesh & | mesh, |
| int | layers ) |
Removes mesh boundary faces (faces which have at least one boundary edge)
| [in,out] | mesh | mesh |
| layers | number of layers of boundary faces to be removed |