MeshLib C Docs
Loading...
Searching...
No Matches
MRMesh.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMesh/MRBox.h>
4#include <MRCMesh/MRId.h>
5#include <MRCMesh/MRVector3.h>
6#include <MRCMisc/common.h>
7#include <MRCMisc/exports.h>
9
10#include <stdbool.h>
11#include <stddef.h>
12
13#ifdef __cplusplus
14extern "C" {
15#endif
16
17typedef struct MR_AABBTree MR_AABBTree; // Defined in `#include <MRCMesh/MRAABBTree.h>`.
18typedef struct MR_AABBTreePoints MR_AABBTreePoints; // Defined in `#include <MRCMesh/MRAABBTreePoints.h>`.
19typedef struct MR_AffineXf3f MR_AffineXf3f; // Defined in `#include <MRCMesh/MRAffineXf.h>`.
20typedef struct MR_Dipoles MR_Dipoles; // Defined in `#include <MRCMesh/MRVector.h>`.
21typedef struct MR_EdgePoint MR_EdgePoint; // Defined in `#include <MRCMesh/MREdgePoint.h>`.
22typedef struct MR_FaceBitSet MR_FaceBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
23typedef struct MR_FaceMap MR_FaceMap; // Defined in `#include <MRCMesh/MRVector.h>`.
24typedef struct MR_LineSegm3f MR_LineSegm3f; // Defined in `#include <MRCMesh/MRLineSegm.h>`.
25typedef struct MR_MeshBuilder_BuildSettings MR_MeshBuilder_BuildSettings; // Defined in `#include <MRCMesh/MRMeshBuilderTypes.h>`.
26typedef struct MR_MeshPart MR_MeshPart; // Defined in `#include <MRCMesh/MRMeshPart.h>`.
27typedef struct MR_MeshProjectionResult MR_MeshProjectionResult; // Defined in `#include <MRCMesh/MRMeshProject.h>`.
28typedef struct MR_MeshTopology MR_MeshTopology; // Defined in `#include <MRCMesh/MRMeshTopology.h>`.
29typedef struct MR_MeshTriPoint MR_MeshTriPoint; // Defined in `#include <MRCMesh/MRMeshTriPoint.h>`.
30typedef struct MR_PackMapping MR_PackMapping; // Defined in `#include <MRCMesh/MRBuffer.h>`.
31typedef struct MR_PartMapping MR_PartMapping; // Defined in `#include <MRCMesh/MRPartMapping.h>`.
32typedef struct MR_Plane3d MR_Plane3d; // Defined in `#include <MRCMesh/MRPlane3.h>`.
33typedef struct MR_Plane3f MR_Plane3f; // Defined in `#include <MRCMesh/MRPlane3.h>`.
34typedef struct MR_PointOnFace MR_PointOnFace; // Defined in `#include <MRCMesh/MRPointOnFace.h>`.
35typedef struct MR_QuadraticForm3f MR_QuadraticForm3f; // Defined in `#include <MRCMesh/MRQuadraticForm.h>`.
36typedef struct MR_TriMesh MR_TriMesh; // Defined in `#include <MRCMesh/MRTriMesh.h>`.
37typedef struct MR_Triangulation MR_Triangulation; // Defined in `#include <MRCMesh/MRVector.h>`.
38typedef struct MR_UndirectedEdgeBitSet MR_UndirectedEdgeBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
39typedef struct MR_UndirectedEdgeScalars MR_UndirectedEdgeScalars; // Defined in `#include <MRCMesh/MRVector.h>`.
40typedef struct MR_Vector_MR_MeshBuilder_VertSpan_MR_FaceId MR_Vector_MR_MeshBuilder_VertSpan_MR_FaceId; // Defined in `#include <MRCMesh/MRVector.h>`.
41typedef struct MR_VertBitSet MR_VertBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
42typedef struct MR_VertCoords MR_VertCoords; // Defined in `#include <MRCMesh/MRVector.h>`.
43typedef struct MR_VertMap MR_VertMap; // Defined in `#include <MRCMesh/MRVector.h>`.
44typedef struct MR_WholeEdgeMap MR_WholeEdgeMap; // Defined in `#include <MRCMesh/MRVector.h>`.
45typedef struct MR_expected_MR_PackMapping_std_string MR_expected_MR_PackMapping_std_string; // Defined in `#include <MRCMisc/expected_MR_PackMapping_std_string.h>`.
46typedef struct MR_expected_MR_VertBitSet_std_string MR_expected_MR_VertBitSet_std_string; // Defined in `#include <MRCMisc/expected_MR_VertBitSet_std_string.h>`.
47typedef struct MR_expected_void_std_string MR_expected_void_std_string; // Defined in `#include <MRCMisc/expected_void_std_string.h>`.
48typedef struct MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId; // Defined in `#include <MRCMisc/phmap_flat_hash_map_MR_FaceId_MR_FaceId.h>`.
49typedef struct MR_std_function_bool_from_float MR_std_function_bool_from_float; // Defined in `#include <MRCMisc/std_function_bool_from_float.h>`.
50typedef struct MR_std_optional_float MR_std_optional_float; // Defined in `#include <MRCMisc/std_optional_float.h>`.
51typedef struct MR_std_vector_MR_MeshBuilder_VertDuplication MR_std_vector_MR_MeshBuilder_VertDuplication; // Defined in `#include <MRCMisc/std_vector_MR_MeshBuilder_VertDuplication.h>`.
52typedef struct MR_std_vector_MR_Vector3f MR_std_vector_MR_Vector3f; // Defined in `#include <MRCMisc/std_vector_MR_Vector3f.h>`.
53typedef struct MR_std_vector_MR_VertId MR_std_vector_MR_VertId; // Defined in `#include <MRCMisc/std_vector_MR_VertId.h>`.
54typedef struct MR_std_vector_std_array_MR_Vector3f_3 MR_std_vector_std_array_MR_Vector3f_3; // Defined in `#include <MRCMisc/std_vector_std_array_MR_Vector3f_3.h>`.
55typedef struct MR_std_vector_std_vector_MR_EdgeId MR_std_vector_std_vector_MR_EdgeId; // Defined in `#include <MRCMisc/std_vector_std_vector_MR_EdgeId.h>`.
56typedef struct MR_std_vector_std_vector_MR_Vector3f MR_std_vector_std_vector_MR_Vector3f; // Defined in `#include <MRCMisc/std_vector_std_vector_MR_Vector3f.h>`.
57
58
62typedef struct MR_Mesh MR_Mesh;
63
68
71MRC_API void MR_Mesh_Set_topology(MR_Mesh *_this, MR_PassBy value_pass_by, MR_MeshTopology *value);
72
77
82
85MRC_API void MR_Mesh_Set_points(MR_Mesh *_this, MR_PassBy value_pass_by, MR_VertCoords *value);
86
91
95
100
102MRC_API const MR_Mesh *MR_Mesh_OffsetPtr(const MR_Mesh *ptr, ptrdiff_t i);
103
106
110
112MRC_API void MR_Mesh_Destroy(const MR_Mesh *_this);
113
116
121
129MRC_API MR_Mesh *MR_Mesh_fromTriangles(MR_PassBy vertexCoordinates_pass_by, MR_VertCoords *vertexCoordinates, const MR_Triangulation *t, const MR_MeshBuilder_BuildSettings *settings, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb);
130
141
151
163
170MRC_API MR_Mesh *MR_Mesh_fromPointTriples(const MR_std_vector_std_array_MR_Vector3f_3 *posTriples, bool duplicateNonManifoldVertices);
171
176MRC_API bool MR_equal_MR_Mesh(const MR_Mesh *_this, const MR_Mesh *b);
177
182
187
192
198
203
209
214
222
227
235
240
246
251
256
261
266
272
279
286
292
299
305
311
317
323
328
334
339
344
349
354
359
365
371
377
383
389MRC_API double MR_Mesh_projArea_MR_FaceBitSet(const MR_Mesh *_this, const MR_Vector3f *dir, const MR_FaceBitSet *fs);
390
397
403MRC_API double MR_Mesh_volume(const MR_Mesh *_this, const MR_FaceBitSet *region);
404
409
415
420
425
430
436
441
446
451
456
463
470
476
486
496
504
514MRC_API MR_std_optional_float *MR_Mesh_signedDistance_3_float(const MR_Mesh *_this, const MR_Vector3f *pt, float maxDistSq, const MR_FaceBitSet *region);
515
525MRC_API float MR_Mesh_calcFastWindingNumber(const MR_Mesh *_this, const MR_Vector3f *pt, const float *beta);
526
534MRC_API bool MR_Mesh_isOutside(const MR_Mesh *_this, const MR_Vector3f *pt, const float *windingNumberThreshold, const float *beta);
535
544MRC_API bool MR_Mesh_isOutsideByProjNorm(const MR_Mesh *_this, const MR_Vector3f *pt, const MR_MeshProjectionResult *proj, const MR_FaceBitSet *region);
545
550MRC_API float MR_Mesh_sumAngles(const MR_Mesh *_this, MR_VertId v, bool *outBoundaryVert);
551
560
568
576
585
591
597
604MRC_API float MR_Mesh_discreteGaussianCurvature(const MR_Mesh *_this, MR_VertId v, bool *outBoundaryVert);
605
611
617
623
632MRC_API MR_QuadraticForm3f *MR_Mesh_quadraticForm(const MR_Mesh *_this, MR_VertId v, bool angleWeigted, const MR_FaceBitSet *region, const MR_UndirectedEdgeBitSet *creases);
633
639
646
653
658
663
668
673
678
686MRC_API void MR_Mesh_transform(MR_Mesh *_this, const MR_AffineXf3f *xf, const MR_VertBitSet *region);
687
693
700
708
717
732
733// same, but split given edge on two equal parts
739
749
750// same, putting new vertex in the centroid of original triangle
756
764MRC_API void MR_Mesh_addMesh_3(MR_Mesh *_this, const MR_Mesh *from, const MR_PartMapping *map, const bool *rearrangeTriangles);
765
772MRC_API void MR_Mesh_addMesh_5(MR_Mesh *_this, const MR_Mesh *from, MR_FaceMap *outFmap, MR_VertMap *outVmap, MR_WholeEdgeMap *outEmap, const bool *rearrangeTriangles);
773
779MRC_API void MR_Mesh_addMeshPart_2(MR_Mesh *_this, const MR_MeshPart *from, const MR_PartMapping *map);
780
793MRC_API void MR_Mesh_addMeshPart_5(MR_Mesh *_this, const MR_MeshPart *from, const bool *flipOrientation, const MR_std_vector_std_vector_MR_EdgeId *thisContours, const MR_std_vector_std_vector_MR_EdgeId *fromContours, const MR_PartMapping *map);
794
803MRC_API MR_Mesh *MR_Mesh_cloneRegion(const MR_Mesh *_this, const MR_FaceBitSet *region, const bool *flipOrientation, const MR_PartMapping *map);
804
811MRC_API void MR_Mesh_pack_2_MR_PartMapping(MR_Mesh *_this, const MR_PartMapping *map, const bool *rearrangeTriangles);
812
818MRC_API void MR_Mesh_pack_4(MR_Mesh *_this, MR_FaceMap *outFmap, MR_VertMap *outVmap, MR_WholeEdgeMap *outEmap, const bool *rearrangeTriangles);
819
828
835MRC_API MR_PackMapping *MR_Mesh_packOptimally_1(MR_Mesh *_this, const bool *preserveAABBTree);
836
841
848
862MRC_API bool MR_Mesh_projectPoint_5_MR_PointOnFace(const MR_Mesh *_this, const MR_Vector3f *point, MR_PointOnFace *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf);
863
877MRC_API bool MR_Mesh_projectPoint_5_MR_MeshProjectionResult(const MR_Mesh *_this, const MR_Vector3f *point, MR_MeshProjectionResult *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf);
878
886MRC_API bool MR_Mesh_findClosestPoint_5(const MR_Mesh *_this, const MR_Vector3f *point, MR_MeshProjectionResult *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf);
887
901MRC_API MR_MeshProjectionResult *MR_Mesh_projectPoint_4(const MR_Mesh *_this, const MR_Vector3f *point, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf);
902
910MRC_API MR_MeshProjectionResult *MR_Mesh_findClosestPoint_4(const MR_Mesh *_this, const MR_Vector3f *point, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf);
911
917
922
928
933
939
944
950MRC_API void MR_Mesh_invalidateCaches(MR_Mesh *_this, const bool *pointsChanged);
951
958MRC_API void MR_Mesh_updateCaches(MR_Mesh *_this, const MR_VertBitSet *changedVerts);
959
960// returns the amount of memory this object occupies on heap
964
969
974MRC_API void MR_Mesh_mirror(MR_Mesh *_this, const MR_Plane3f *plane);
975
976#ifdef __cplusplus
977} // extern "C"
978#endif
struct MR_std_vector_std_vector_MR_EdgeId MR_std_vector_std_vector_MR_EdgeId
Definition MR2DContoursTriangulation.h:19
struct MR_MeshTopology MR_MeshTopology
Definition MR2DContoursTriangulation.h:16
struct MR_std_function_bool_from_float MR_std_function_bool_from_float
Definition MR3mf.h:10
struct MR_FaceBitSet MR_FaceBitSet
Definition MRAABBTreeBase.h:25
struct MR_UndirectedEdgeBitSet MR_UndirectedEdgeBitSet
Definition MRAABBTreeBase.h:29
struct MR_VertCoords MR_VertCoords
Definition MRAABBTreePoints.h:22
struct MR_AABBTreePoints MR_AABBTreePoints
Definition MRAABBTreePoints.h:29
struct MR_VertBitSet MR_VertBitSet
Definition MRAABBTree.h:15
struct MR_AABBTree MR_AABBTree
Definition MRAABBTree.h:23
struct MR_MeshPart MR_MeshPart
Definition MRAABBTree.h:14
struct MR_MeshTriPoint MR_MeshTriPoint
Definition MRAggregateFlow.h:13
struct MR_UndirectedEdgeScalars MR_UndirectedEdgeScalars
Definition MRAggregateFlow.h:16
struct MR_std_optional_float MR_std_optional_float
Definition MRBestFitPolynomial.h:14
struct MR_Plane3d MR_Plane3d
Definition MRBestFit.h:22
struct MR_Plane3f MR_Plane3f
Definition MRBestFit.h:23
struct MR_std_vector_MR_Vector3f MR_std_vector_MR_Vector3f
Definition MRBestFit.h:26
struct MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId
Definition MRBitSet.h:43
struct MR_VertMap MR_VertMap
Definition MRBitSet.h:41
struct MR_FaceMap MR_FaceMap
Definition MRBitSet.h:27
struct MR_WholeEdgeMap MR_WholeEdgeMap
Definition MRBooleanOperation.h:21
struct MR_PackMapping MR_PackMapping
Definition MRBuffer.h:374
struct MR_std_vector_std_vector_MR_Vector3f MR_std_vector_std_vector_MR_Vector3f
Definition MRContour.h:17
struct MR_expected_void_std_string MR_expected_void_std_string
Definition MRCtm.h:20
struct MR_Mesh MR_Mesh
Definition MRCtm.h:13
struct MR_Dipoles MR_Dipoles
Definition MRDipole.h:15
struct MR_std_vector_MR_VertId MR_std_vector_MR_VertId
Definition MREdgePaths.h:30
struct MR_EdgePoint MR_EdgePoint
Definition MREdgePoint.h:21
struct MR_PointOnFace MR_PointOnFace
Definition MREnumNeighbours.h:15
struct MR_LineSegm3f MR_LineSegm3f
Definition MRFeatures.h:19
struct MR_Triangulation MR_Triangulation
Definition MRIdentifyVertices.h:13
struct MR_std_vector_std_array_MR_Vector3f_3 MR_std_vector_std_array_MR_Vector3f_3
Definition MRIdentifyVertices.h:16
MRC_API float MR_Mesh_averageEdgeLength(const MR_Mesh *_this)
MRC_API void MR_Mesh_addMeshPart_5(MR_Mesh *_this, const MR_MeshPart *from, const bool *flipOrientation, const MR_std_vector_std_vector_MR_EdgeId *thisContours, const MR_std_vector_std_vector_MR_EdgeId *fromContours, const MR_PartMapping *map)
MRC_API void MR_Mesh_transform(MR_Mesh *_this, const MR_AffineXf3f *xf, const MR_VertBitSet *region)
MRC_API MR_Mesh * MR_Mesh_cloneRegion(const MR_Mesh *_this, const MR_FaceBitSet *region, const bool *flipOrientation, const MR_PartMapping *map)
MRC_API float MR_Mesh_dblArea_MR_VertId(const MR_Mesh *_this, MR_VertId v)
MRC_API MR_Mesh * MR_Mesh_OffsetMutablePtr(MR_Mesh *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API float MR_Mesh_area_MR_FaceId(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_EdgeId MR_Mesh_addSeparateEdgeLoop(MR_Mesh *_this, const MR_std_vector_MR_Vector3f *contourPoints)
MRC_API void MR_Mesh_Destroy(const MR_Mesh *_this)
Destroys a heap-allocated instance of MR_Mesh. Does nothing if the pointer is null.
MRC_API void MR_Mesh_getTriPoints_4(const MR_Mesh *_this, MR_FaceId f, MR_Vector3f *v0, MR_Vector3f *v1, MR_Vector3f *v2)
MRC_API MR_Vector3f MR_Mesh_leftDirDblArea(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_Box3f MR_Mesh_computeBoundingBox_1(const MR_Mesh *_this, const MR_AffineXf3f *toWorld)
MRC_API const MR_AABBTree * MR_Mesh_getAABBTreeNotCreate(const MR_Mesh *_this)
MRC_API void MR_Mesh_updateCaches(MR_Mesh *_this, const MR_VertBitSet *changedVerts)
MRC_API MR_Vector3f MR_Mesh_findCenterFromPoints(const MR_Mesh *_this)
MRC_API bool MR_Mesh_projectPoint_5_MR_PointOnFace(const MR_Mesh *_this, const MR_Vector3f *point, MR_PointOnFace *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf)
MRC_API MR_Vector3f MR_Mesh_pseudonormal_MR_MeshTriPoint(const MR_Mesh *_this, const MR_MeshTriPoint *p, const MR_FaceBitSet *region)
MRC_API MR_Vector3f MR_Mesh_leftTangent(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_Mesh * MR_Mesh_fromTrianglesDuplicatingNonManifoldVertices(MR_PassBy vertexCoordinates_pass_by, MR_VertCoords *vertexCoordinates, MR_Triangulation *t, MR_std_vector_MR_MeshBuilder_VertDuplication *dups, const MR_MeshBuilder_BuildSettings *settings)
MRC_API MR_VertId MR_Mesh_getClosestVertex_MR_MeshTriPoint(const MR_Mesh *_this, const MR_MeshTriPoint *p)
MRC_API MR_Mesh * MR_Mesh_fromFaceSoup(MR_PassBy vertexCoordinates_pass_by, MR_VertCoords *vertexCoordinates, const MR_std_vector_MR_VertId *verts, const MR_Vector_MR_MeshBuilder_VertSpan_MR_FaceId *faces, const MR_MeshBuilder_BuildSettings *settings, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb)
MRC_API MR_Vector3d MR_Mesh_dirArea_const_MR_FaceBitSet_ptr(const MR_Mesh *_this, const MR_FaceBitSet *fs)
MRC_API MR_Box3f MR_Mesh_getBoundingBox(const MR_Mesh *_this)
MRC_API MR_VertId MR_Mesh_splitFace_4(MR_Mesh *_this, MR_FaceId f, const MR_Vector3f *newVertPos, MR_FaceBitSet *region, MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId *new2Old)
MRC_API double MR_Mesh_area_const_MR_FaceBitSet_ptr(const MR_Mesh *_this, const MR_FaceBitSet *fs)
MRC_API const MR_AABBTree * MR_Mesh_getAABBTree(const MR_Mesh *_this)
struct MR_MeshProjectionResult MR_MeshProjectionResult
Definition MRMesh.h:27
MRC_API MR_Plane3d * MR_Mesh_getPlane3d(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Box3f MR_Mesh_computeBoundingBox_2(const MR_Mesh *_this, const MR_FaceBitSet *region, const MR_AffineXf3f *toWorld)
MRC_API float MR_Mesh_signedDistance_3_MR_MeshProjectionResult(const MR_Mesh *_this, const MR_Vector3f *pt, const MR_MeshProjectionResult *proj, const MR_FaceBitSet *region)
MRC_API float MR_Mesh_dihedralAngle(const MR_Mesh *_this, MR_UndirectedEdgeId e)
struct MR_Vector_MR_MeshBuilder_VertSpan_MR_FaceId MR_Vector_MR_MeshBuilder_VertSpan_MR_FaceId
Definition MRMesh.h:40
MRC_API float MR_Mesh_circumcircleDiameter(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Vector3f MR_Mesh_edgePoint_2(const MR_Mesh *_this, MR_EdgeId e, float f)
MRC_API float MR_Mesh_cotan(const MR_Mesh *_this, MR_UndirectedEdgeId ue)
MRC_API MR_EdgePoint * MR_Mesh_toEdgePoint_1(const MR_Mesh *_this, MR_VertId v)
MRC_API MR_Vector3d MR_Mesh_dirArea_MR_FaceBitSet(const MR_Mesh *_this, const MR_FaceBitSet *fs)
MRC_API MR_Vector3f MR_Mesh_findCenterFromFaces(const MR_Mesh *_this)
MRC_API const MR_AABBTreePoints * MR_Mesh_getAABBTreePointsNotCreate(const MR_Mesh *_this)
MRC_API void MR_Mesh_deleteFaces(MR_Mesh *_this, const MR_FaceBitSet *fs, const MR_UndirectedEdgeBitSet *keepEdges)
MRC_API MR_EdgeId MR_Mesh_addSeparateContours(MR_Mesh *_this, const MR_std_vector_std_vector_MR_Vector3f *contours, const MR_AffineXf3f *xf)
struct MR_QuadraticForm3f MR_QuadraticForm3f
Definition MRMesh.h:35
MRC_API float MR_Mesh_leftCotan(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_Vector3f MR_Mesh_edgeCenter(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API void MR_Mesh_addMesh_3(MR_Mesh *_this, const MR_Mesh *from, const MR_PartMapping *map, const bool *rearrangeTriangles)
struct MR_std_vector_MR_MeshBuilder_VertDuplication MR_std_vector_MR_MeshBuilder_VertDuplication
Definition MRMesh.h:51
MRC_API MR_Vector3d MR_Mesh_holeDirArea(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_Mesh * MR_Mesh_DefaultConstructArray(size_t num_elems)
MRC_API MR_expected_MR_VertBitSet_std_string * MR_Mesh_findSpikeVertices(const MR_Mesh *_this, float minSumAngle, const MR_VertBitSet *region, const MR_std_function_bool_from_float *cb)
MRC_API MR_Vector3f MR_Mesh_normal_MR_MeshTriPoint(const MR_Mesh *_this, const MR_MeshTriPoint *p)
MRC_API MR_UndirectedEdgeId MR_Mesh_getClosestEdge_MR_MeshTriPoint(const MR_Mesh *_this, const MR_MeshTriPoint *p)
MRC_API MR_std_optional_float * MR_Mesh_signedDistance_3_float(const MR_Mesh *_this, const MR_Vector3f *pt, float maxDistSq, const MR_FaceBitSet *region)
MRC_API MR_EdgePoint * MR_Mesh_toEdgePoint_2(const MR_Mesh *_this, MR_EdgeId e, const MR_Vector3f *p)
MRC_API MR_Mesh * MR_Mesh_AssignFromAnother(MR_Mesh *_this, MR_PassBy _other_pass_by, MR_Mesh *_other)
MRC_API const MR_AABBTreePoints * MR_Mesh_getAABBTreePoints(const MR_Mesh *_this)
MRC_API const MR_VertCoords * MR_Mesh_Get_points(const MR_Mesh *_this)
MRC_API MR_Mesh * MR_Mesh_fromTriMesh(MR_TriMesh *triMesh, const MR_MeshBuilder_BuildSettings *settings, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb)
MRC_API const MR_Dipoles * MR_Mesh_getDipolesNotCreate(const MR_Mesh *_this)
MRC_API void MR_Mesh_getLeftTriPoints_4(const MR_Mesh *_this, MR_EdgeId e, MR_Vector3f *v0, MR_Vector3f *v1, MR_Vector3f *v2)
MRC_API MR_EdgeId MR_Mesh_splitEdge_4(MR_Mesh *_this, MR_EdgeId e, const MR_Vector3f *newVertPos, MR_FaceBitSet *region, MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId *new2Old)
MRC_API MR_Vector3f MR_Mesh_edgePoint_1(const MR_Mesh *_this, const MR_EdgePoint *ep)
MRC_API float MR_Mesh_triangleAspectRatio(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Vector3f MR_Mesh_triPoint(const MR_Mesh *_this, const MR_MeshTriPoint *p)
MRC_API MR_MeshTriPoint * MR_Mesh_toTriPoint_1_MR_PointOnFace(const MR_Mesh *_this, const MR_PointOnFace *p)
MRC_API MR_EdgeId MR_Mesh_splitEdge_3(MR_Mesh *_this, MR_EdgeId e, MR_FaceBitSet *region, MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId *new2Old)
MRC_API void MR_Mesh_mirror(MR_Mesh *_this, const MR_Plane3f *plane)
MRC_API MR_VertId MR_Mesh_getClosestVertex_MR_PointOnFace(const MR_Mesh *_this, const MR_PointOnFace *p)
MRC_API double MR_Mesh_holePerimiter(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_Vector3f MR_Mesh_findCenterFromBBox(const MR_Mesh *_this)
MRC_API float MR_Mesh_edgeLength(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API MR_Vector3f MR_Mesh_dirDblArea_MR_FaceId(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Vector3f MR_Mesh_orgPnt(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_UndirectedEdgeBitSet * MR_Mesh_findCreaseEdges(const MR_Mesh *_this, float angleFromPlanar)
MRC_API float MR_Mesh_circumcircleDiameterSq(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_MeshTopology * MR_Mesh_GetMutable_topology(MR_Mesh *_this)
MRC_API MR_Plane3f * MR_Mesh_getPlane3f(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_UndirectedEdgeId MR_Mesh_getClosestEdge_MR_PointOnFace(const MR_Mesh *_this, const MR_PointOnFace *p)
MRC_API float MR_Mesh_dihedralAngleSin(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API float MR_Mesh_discreteMeanCurvature_MR_VertId(const MR_Mesh *_this, MR_VertId v)
MRC_API MR_Mesh * MR_Mesh_fromTriangles(MR_PassBy vertexCoordinates_pass_by, MR_VertCoords *vertexCoordinates, const MR_Triangulation *t, const MR_MeshBuilder_BuildSettings *settings, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb)
MRC_API MR_QuadraticForm3f * MR_Mesh_quadraticForm(const MR_Mesh *_this, MR_VertId v, bool angleWeigted, const MR_FaceBitSet *region, const MR_UndirectedEdgeBitSet *creases)
MRC_API MR_Vector3f MR_Mesh_leftNormal(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_VertCoords * MR_Mesh_GetMutable_points(MR_Mesh *_this)
MRC_API float MR_Mesh_discreteMeanCurvature_MR_UndirectedEdgeId(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API bool MR_equal_MR_Mesh(const MR_Mesh *_this, const MR_Mesh *b)
MRC_API float MR_Mesh_calcFastWindingNumber(const MR_Mesh *_this, const MR_Vector3f *pt, const float *beta)
MRC_API double MR_Mesh_volume(const MR_Mesh *_this, const MR_FaceBitSet *region)
MRC_API float MR_Mesh_sumAngles(const MR_Mesh *_this, MR_VertId v, bool *outBoundaryVert)
MRC_API const MR_MeshTopology * MR_Mesh_Get_topology(const MR_Mesh *_this)
MRC_API bool MR_Mesh_projectPoint_5_MR_MeshProjectionResult(const MR_Mesh *_this, const MR_Vector3f *point, MR_MeshProjectionResult *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf)
MRC_API MR_Vector3f MR_Mesh_pseudonormal_MR_UndirectedEdgeId(const MR_Mesh *_this, MR_UndirectedEdgeId e, const MR_FaceBitSet *region)
MRC_API void MR_Mesh_DestroyArray(const MR_Mesh *_this)
Destroys a heap-allocated array of MR_Mesh. Does nothing if the pointer is null.
MRC_API void MR_Mesh_attachEdgeLoopPart(MR_Mesh *_this, MR_EdgeId first, MR_EdgeId last, const MR_std_vector_MR_Vector3f *contourPoints)
MRC_API void MR_Mesh_Set_topology(MR_Mesh *_this, MR_PassBy value_pass_by, MR_MeshTopology *value)
MRC_API MR_Mesh * MR_Mesh_fromPointTriples(const MR_std_vector_std_array_MR_Vector3f_3 *posTriples, bool duplicateNonManifoldVertices)
MRC_API MR_Vector3f MR_Mesh_edgeVector(const MR_Mesh *_this, MR_EdgeId e)
MRC_API MR_expected_MR_PackMapping_std_string * MR_Mesh_packOptimally_2(MR_Mesh *_this, bool preserveAABBTree, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb)
MRC_API MR_VertId MR_Mesh_addPoint(MR_Mesh *_this, const MR_Vector3f *pos)
MRC_API void MR_Mesh_addMeshPart_2(MR_Mesh *_this, const MR_MeshPart *from, const MR_PartMapping *map)
MRC_API MR_std_array_MR_Vector3f_3 MR_Mesh_getLeftTriPoints_1(const MR_Mesh *_this, MR_EdgeId e)
MRC_API float MR_Mesh_discreteGaussianCurvature(const MR_Mesh *_this, MR_VertId v, bool *outBoundaryVert)
MRC_API MR_std_array_MR_Vector3f_3 MR_Mesh_getTriPoints_1(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Mesh * MR_Mesh_ConstructFromAnother(MR_PassBy _other_pass_by, MR_Mesh *_other)
struct MR_TriMesh MR_TriMesh
Definition MRMesh.h:36
MRC_API void MR_Mesh_invalidateCaches(MR_Mesh *_this, const bool *pointsChanged)
MRC_API const MR_Mesh * MR_Mesh_OffsetPtr(const MR_Mesh *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
MRC_API void MR_Mesh_Set_points(MR_Mesh *_this, MR_PassBy value_pass_by, MR_VertCoords *value)
MRC_API float MR_Mesh_dblArea_MR_FaceId(const MR_Mesh *_this, MR_FaceId f)
MRC_API void MR_Mesh_pack_2_MR_PartMapping(MR_Mesh *_this, const MR_PartMapping *map, const bool *rearrangeTriangles)
struct MR_PartMapping MR_PartMapping
Definition MRMesh.h:31
MRC_API MR_MeshTriPoint * MR_Mesh_toTriPoint_2(const MR_Mesh *_this, MR_FaceId f, const MR_Vector3f *p)
MRC_API MR_expected_void_std_string * MR_Mesh_pack_2_MR_PackMapping(MR_Mesh *_this, const MR_PackMapping *map, MR_PassBy cb_pass_by, MR_std_function_bool_from_float *cb)
MRC_API MR_MeshProjectionResult * MR_Mesh_projectPoint_4(const MR_Mesh *_this, const MR_Vector3f *point, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf)
struct MR_expected_MR_PackMapping_std_string MR_expected_MR_PackMapping_std_string
Definition MRMesh.h:45
MRC_API double MR_Mesh_area_MR_FaceBitSet(const MR_Mesh *_this, const MR_FaceBitSet *fs)
MRC_API const MR_Dipoles * MR_Mesh_getDipoles(const MR_Mesh *_this)
MRC_API MR_UndirectedEdgeScalars * MR_Mesh_edgeLengths(const MR_Mesh *_this)
struct MR_expected_MR_VertBitSet_std_string MR_expected_MR_VertBitSet_std_string
Definition MRMesh.h:46
MRC_API MR_MeshTriPoint * MR_Mesh_toTriPoint_1_MR_VertId(const MR_Mesh *_this, MR_VertId v)
struct MR_MeshBuilder_BuildSettings MR_MeshBuilder_BuildSettings
Definition MRMesh.h:25
MRC_API float MR_Mesh_dihedralAngleCos(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API MR_LineSegm3f * MR_Mesh_edgeSegment(const MR_Mesh *_this, MR_EdgeId e)
MRC_API void MR_Mesh_shrinkToFit(MR_Mesh *_this)
MRC_API MR_VertId MR_Mesh_splitFace_3(MR_Mesh *_this, MR_FaceId f, MR_FaceBitSet *region, MR_phmap_flat_hash_map_MR_FaceId_MR_FaceId *new2Old)
MRC_API void MR_Mesh_pack_4(MR_Mesh *_this, MR_FaceMap *outFmap, MR_VertMap *outVmap, MR_WholeEdgeMap *outEmap, const bool *rearrangeTriangles)
MRC_API MR_Vector3f MR_Mesh_dirDblArea_MR_VertId(const MR_Mesh *_this, MR_VertId v)
MRC_API MR_Mesh * MR_Mesh_DefaultConstruct(void)
MRC_API MR_uint64_t MR_Mesh_heapBytes(const MR_Mesh *_this)
MRC_API float MR_Mesh_edgeLengthSq(const MR_Mesh *_this, MR_UndirectedEdgeId e)
MRC_API bool MR_Mesh_findClosestPoint_5(const MR_Mesh *_this, const MR_Vector3f *point, MR_MeshProjectionResult *res, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf)
MRC_API MR_Vector3f MR_Mesh_destPnt(const MR_Mesh *_this, MR_EdgeId e)
MRC_API double MR_Mesh_projArea_MR_FaceBitSet(const MR_Mesh *_this, const MR_Vector3f *dir, const MR_FaceBitSet *fs)
MRC_API MR_MeshProjectionResult * MR_Mesh_findClosestPoint_4(const MR_Mesh *_this, const MR_Vector3f *point, const float *maxDistSq, const MR_FaceBitSet *region, const MR_AffineXf3f *xf)
MRC_API void MR_Mesh_zeroUnusedPoints(MR_Mesh *_this)
MRC_API bool MR_Mesh_isOutsideByProjNorm(const MR_Mesh *_this, const MR_Vector3f *pt, const MR_MeshProjectionResult *proj, const MR_FaceBitSet *region)
MRC_API float MR_Mesh_signedDistance_1(const MR_Mesh *_this, const MR_Vector3f *pt)
MRC_API MR_Vector3f MR_Mesh_pseudonormal_MR_VertId(const MR_Mesh *_this, MR_VertId v, const MR_FaceBitSet *region)
MRC_API bool MR_Mesh_isOutside(const MR_Mesh *_this, const MR_Vector3f *pt, const float *windingNumberThreshold, const float *beta)
MRC_API void MR_Mesh_addMesh_5(MR_Mesh *_this, const MR_Mesh *from, MR_FaceMap *outFmap, MR_VertMap *outVmap, MR_WholeEdgeMap *outEmap, const bool *rearrangeTriangles)
MRC_API MR_PackMapping * MR_Mesh_packOptimally_1(MR_Mesh *_this, const bool *preserveAABBTree)
MRC_API MR_Vector3f MR_Mesh_normal_MR_FaceId(const MR_Mesh *_this, MR_FaceId f)
MRC_API MR_Vector3f MR_Mesh_normal_MR_VertId(const MR_Mesh *_this, MR_VertId v)
MRC_API MR_Vector3f MR_Mesh_triCenter(const MR_Mesh *_this, MR_FaceId f)
MRC_API double MR_Mesh_projArea_const_MR_FaceBitSet_ptr(const MR_Mesh *_this, const MR_Vector3f *dir, const MR_FaceBitSet *fs)
MR_PassBy
Definition common.h:19
uint64_t MR_uint64_t
Definition common.h:14
#define MRC_API
Definition exports.h:11
Definition MRAffineXf.h:36
Definition MRBox.h:109
Definition MRId.h:152
Definition MRId.h:46
Definition MRId.h:36
Definition MRVector3.h:60
Definition MRVector3.h:51
Definition MRId.h:56
A fixed-size array of MR::Vector3f of size 3.
Definition std_array_MR_Vector3f_3.h:12