MeshLib C Docs
Loading...
Searching...
No Matches
MRBooleanOperation.h
Go to the documentation of this file.
1#pragma once
2
3#include <MRCMisc/common.h>
4#include <MRCMisc/exports.h>
5
6#include <stdbool.h>
7#include <stddef.h>
8#include <stdint.h>
9
10#ifdef __cplusplus
11extern "C" {
12#endif
13
14typedef struct MR_AffineXf3f MR_AffineXf3f; // Defined in `#include <MRCMesh/MRAffineXf.h>`.
15typedef struct MR_EdgeBitSet MR_EdgeBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
16typedef struct MR_FaceBitSet MR_FaceBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
17typedef struct MR_FaceMap MR_FaceMap; // Defined in `#include <MRCMesh/MRVector.h>`.
18typedef struct MR_Mesh MR_Mesh; // Defined in `#include <MRCMesh/MRMesh.h>`.
19typedef struct MR_VertBitSet MR_VertBitSet; // Defined in `#include <MRCMesh/MRBitSet.h>`.
20typedef struct MR_VertMap MR_VertMap; // Defined in `#include <MRCMesh/MRVector.h>`.
21typedef struct MR_WholeEdgeMap MR_WholeEdgeMap; // Defined in `#include <MRCMesh/MRVector.h>`.
22typedef struct MR_expected_MR_Mesh_std_string MR_expected_MR_Mesh_std_string; // Defined in `#include <MRCMisc/expected_MR_Mesh_std_string.h>`.
23typedef struct MR_std_array_MR_BooleanResultMapper_Maps_2 MR_std_array_MR_BooleanResultMapper_Maps_2; // Defined in `#include <MRCMisc/std_array_MR_BooleanResultMapper_Maps_2.h>`.
24typedef 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>`.
25
26
32typedef int32_t MR_BooleanOperation;
33enum // MR_BooleanOperation
34{
61};
62
72
75enum // MR_BooleanResultMapper_MapObject
76{
80};
81
84
88
93
97
102
106
111
114
117
121
124
127
132
139
146
153
159
166
171
178
184
191
197
202
208
214
219
225
231
236
242
248
253
259
263
268
271MRC_API MR_BooleanResultMapper_Maps *MR_BooleanResultMapper_Maps_ConstructFrom(MR_PassBy cut2origin_pass_by, MR_FaceMap *cut2origin, MR_PassBy cut2newFaces_pass_by, MR_FaceMap *cut2newFaces, MR_PassBy old2newEdges_pass_by, MR_WholeEdgeMap *old2newEdges, MR_PassBy old2newVerts_pass_by, MR_VertMap *old2newVerts, bool identity);
272
275
278
282
285
288
293
299
304
310
316
321
327
333
338
344
348
353
357
360
363
368
371
374
380
399MRC_API MR_expected_MR_Mesh_std_string *MR_doBooleanOperation(MR_Mesh *meshACut, MR_Mesh *meshBCut, const MR_std_vector_std_vector_MR_EdgeId *cutEdgesA, const MR_std_vector_std_vector_MR_EdgeId *cutEdgesB, MR_BooleanOperation operation, const MR_AffineXf3f *rigidB2A, MR_BooleanResultMapper *mapper, const bool *mergeAllNonIntersectingComponents, const MR_BooleanInternalParameters *intParams);
400
401#ifdef __cplusplus
402} // extern "C"
403#endif
struct MR_std_vector_std_vector_MR_EdgeId MR_std_vector_std_vector_MR_EdgeId
Definition MR2DContoursTriangulation.h:19
struct MR_FaceBitSet MR_FaceBitSet
Definition MRAABBTreeBase.h:25
struct MR_VertBitSet MR_VertBitSet
Definition MRAABBTree.h:15
struct MR_EdgeBitSet MR_EdgeBitSet
Definition MRBitSet.h:79
struct MR_VertMap MR_VertMap
Definition MRBitSet.h:41
struct MR_FaceMap MR_FaceMap
Definition MRBitSet.h:27
MRC_API MR_BooleanInternalParameters * MR_BooleanInternalParameters_AssignFromAnother(MR_BooleanInternalParameters *_this, const MR_BooleanInternalParameters *_other)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_ConstructFromAnother(MR_PassBy _other_pass_by, MR_BooleanResultMapper_Maps *_other)
MRC_API const MR_BooleanInternalParameters * MR_BooleanInternalParameters_OffsetPtr(const MR_BooleanInternalParameters *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 const MR_Mesh *const * MR_BooleanInternalParameters_Get_originalMeshA(const MR_BooleanInternalParameters *_this)
MRC_API MR_std_array_MR_BooleanResultMapper_Maps_2 * MR_BooleanResultMapper_GetMutable_maps(MR_BooleanResultMapper *_this)
MRC_API const MR_Mesh *const * MR_BooleanInternalParameters_Get_originalMeshB(const MR_BooleanInternalParameters *_this)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_DefaultConstructArray(size_t num_elems)
MRC_API const MR_std_array_MR_BooleanResultMapper_Maps_2 * MR_BooleanResultMapper_Get_maps(const MR_BooleanResultMapper *_this)
MRC_API MR_BooleanResultMapper * MR_BooleanResultMapper_AssignFromAnother(MR_BooleanResultMapper *_this, MR_PassBy _other_pass_by, MR_BooleanResultMapper *_other)
struct MR_BooleanInternalParameters MR_BooleanInternalParameters
Definition MRBooleanOperation.h:87
MRC_API void MR_BooleanResultMapper_Maps_Set_old2newVerts(MR_BooleanResultMapper_Maps *_this, MR_PassBy value_pass_by, MR_VertMap *value)
MRC_API MR_expected_MR_Mesh_std_string * MR_doBooleanOperation(MR_Mesh *meshACut, MR_Mesh *meshBCut, const MR_std_vector_std_vector_MR_EdgeId *cutEdgesA, const MR_std_vector_std_vector_MR_EdgeId *cutEdgesB, MR_BooleanOperation operation, const MR_AffineXf3f *rigidB2A, MR_BooleanResultMapper *mapper, const bool *mergeAllNonIntersectingComponents, const MR_BooleanInternalParameters *intParams)
MRC_API void MR_BooleanResultMapper_Set_maps(MR_BooleanResultMapper *_this, MR_PassBy value_pass_by, MR_std_array_MR_BooleanResultMapper_Maps_2 *value)
MRC_API MR_FaceMap * MR_BooleanResultMapper_Maps_GetMutable_cut2origin(MR_BooleanResultMapper_Maps *_this)
MRC_API void MR_BooleanResultMapper_Destroy(const MR_BooleanResultMapper *_this)
Destroys a heap-allocated instance of MR_BooleanResultMapper. Does nothing if the pointer is null.
MRC_API void MR_BooleanInternalParameters_DestroyArray(const MR_BooleanInternalParameters *_this)
Destroys a heap-allocated array of MR_BooleanInternalParameters. Does nothing if the pointer is null.
struct MR_WholeEdgeMap MR_WholeEdgeMap
Definition MRBooleanOperation.h:21
struct MR_BooleanResultMapper MR_BooleanResultMapper
Generated from class MR::BooleanResultMapper.
Definition MRBooleanOperation.h:71
MRC_API MR_std_vector_std_vector_MR_EdgeId *const * MR_BooleanInternalParameters_Get_optionalOutCut(const MR_BooleanInternalParameters *_this)
MRC_API MR_BooleanResultMapper * MR_BooleanResultMapper_DefaultConstruct(void)
struct MR_std_array_MR_BooleanResultMapper_Maps_2 MR_std_array_MR_BooleanResultMapper_Maps_2
Definition MRBooleanOperation.h:23
MRC_API bool * MR_BooleanResultMapper_Maps_GetMutable_identity(MR_BooleanResultMapper_Maps *_this)
MRC_API const MR_FaceMap * MR_BooleanResultMapper_Maps_Get_cut2newFaces(const MR_BooleanResultMapper_Maps *_this)
MRC_API MR_BooleanResultMapper * MR_BooleanResultMapper_DefaultConstructArray(size_t num_elems)
MRC_API MR_VertBitSet * MR_BooleanResultMapper_map_MR_VertBitSet(const MR_BooleanResultMapper *_this, const MR_VertBitSet *oldBS, MR_BooleanResultMapper_MapObject obj)
MRC_API MR_BooleanResultMapper * MR_BooleanResultMapper_OffsetMutablePtr(MR_BooleanResultMapper *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_BooleanInternalParameters_Set_optionalOutCut(MR_BooleanInternalParameters *_this, MR_std_vector_std_vector_MR_EdgeId *value)
struct MR_BooleanResultMapper_Maps MR_BooleanResultMapper_Maps
Generated from class MR::BooleanResultMapper::Maps.
Definition MRBooleanOperation.h:83
MRC_API void MR_BooleanInternalParameters_Destroy(const MR_BooleanInternalParameters *_this)
Destroys a heap-allocated instance of MR_BooleanInternalParameters. Does nothing if the pointer is nu...
MRC_API void MR_BooleanInternalParameters_Set_originalMeshA(MR_BooleanInternalParameters *_this, const MR_Mesh *value)
MRC_API MR_FaceBitSet * MR_BooleanResultMapper_map_MR_FaceBitSet(const MR_BooleanResultMapper *_this, const MR_FaceBitSet *oldBS, MR_BooleanResultMapper_MapObject obj)
MRC_API const MR_FaceMap * MR_BooleanResultMapper_Maps_Get_cut2origin(const MR_BooleanResultMapper_Maps *_this)
int32_t MR_BooleanOperation
Definition MRBooleanOperation.h:32
MRC_API MR_EdgeBitSet * MR_BooleanResultMapper_map_MR_EdgeBitSet(const MR_BooleanResultMapper *_this, const MR_EdgeBitSet *oldBS, MR_BooleanResultMapper_MapObject obj)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_AssignFromAnother(MR_BooleanResultMapper_Maps *_this, MR_PassBy _other_pass_by, MR_BooleanResultMapper_Maps *_other)
MRC_API void MR_BooleanResultMapper_Maps_Set_cut2origin(MR_BooleanResultMapper_Maps *_this, MR_PassBy value_pass_by, MR_FaceMap *value)
MRC_API void MR_BooleanResultMapper_Maps_DestroyArray(const MR_BooleanResultMapper_Maps *_this)
Destroys a heap-allocated array of MR_BooleanResultMapper_Maps. Does nothing if the pointer is null.
MRC_API MR_FaceBitSet * MR_BooleanResultMapper_filteredOldFaceBitSet(MR_BooleanResultMapper *_this, const MR_FaceBitSet *oldBS, MR_BooleanResultMapper_MapObject obj)
MRC_API const MR_Mesh ** MR_BooleanInternalParameters_GetMutable_originalMeshA(MR_BooleanInternalParameters *_this)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_OffsetMutablePtr(MR_BooleanResultMapper_Maps *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 const MR_VertMap * MR_BooleanResultMapper_Maps_Get_old2newVerts(const MR_BooleanResultMapper_Maps *_this)
MRC_API void MR_BooleanResultMapper_Maps_Destroy(const MR_BooleanResultMapper_Maps *_this)
Destroys a heap-allocated instance of MR_BooleanResultMapper_Maps. Does nothing if the pointer is nul...
MRC_API MR_BooleanInternalParameters * MR_BooleanInternalParameters_ConstructFrom(const MR_Mesh *originalMeshA, const MR_Mesh *originalMeshB, MR_std_vector_std_vector_MR_EdgeId *optionalOutCut)
int32_t MR_BooleanResultMapper_MapObject
Input object index enum.
Definition MRBooleanOperation.h:74
MRC_API const bool * MR_BooleanResultMapper_Maps_Get_identity(const MR_BooleanResultMapper_Maps *_this)
MRC_API MR_VertMap * MR_BooleanResultMapper_Maps_GetMutable_old2newVerts(MR_BooleanResultMapper_Maps *_this)
MRC_API MR_BooleanInternalParameters * MR_BooleanInternalParameters_ConstructFromAnother(const MR_BooleanInternalParameters *_other)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_DefaultConstruct(void)
MRC_API MR_std_vector_std_vector_MR_EdgeId ** MR_BooleanInternalParameters_GetMutable_optionalOutCut(MR_BooleanInternalParameters *_this)
MRC_API MR_BooleanInternalParameters * MR_BooleanInternalParameters_DefaultConstructArray(size_t num_elems)
MRC_API MR_FaceMap * MR_BooleanResultMapper_Maps_GetMutable_cut2newFaces(MR_BooleanResultMapper_Maps *_this)
MRC_API void MR_BooleanInternalParameters_Set_originalMeshB(MR_BooleanInternalParameters *_this, const MR_Mesh *value)
MRC_API MR_WholeEdgeMap * MR_BooleanResultMapper_Maps_GetMutable_old2newEdges(MR_BooleanResultMapper_Maps *_this)
MRC_API const MR_Mesh ** MR_BooleanInternalParameters_GetMutable_originalMeshB(MR_BooleanInternalParameters *_this)
@ MR_BooleanOperation_Union
Definition MRBooleanOperation.h:49
@ MR_BooleanOperation_DifferenceBA
Definition MRBooleanOperation.h:55
@ MR_BooleanOperation_Count
Definition MRBooleanOperation.h:60
@ MR_BooleanOperation_InsideB
Definition MRBooleanOperation.h:40
@ MR_BooleanOperation_Intersection
Definition MRBooleanOperation.h:52
@ MR_BooleanOperation_OutsideB
Definition MRBooleanOperation.h:46
@ MR_BooleanOperation_InsideA
Definition MRBooleanOperation.h:37
@ MR_BooleanOperation_DifferenceAB
not a valid operation
Definition MRBooleanOperation.h:58
@ MR_BooleanOperation_OutsideA
Definition MRBooleanOperation.h:43
MRC_API const MR_BooleanResultMapper * MR_BooleanResultMapper_OffsetPtr(const MR_BooleanResultMapper *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 MR_BooleanInternalParameters * MR_BooleanInternalParameters_DefaultConstruct(void)
MRC_API void MR_BooleanResultMapper_Maps_Set_cut2newFaces(MR_BooleanResultMapper_Maps *_this, MR_PassBy value_pass_by, MR_FaceMap *value)
MRC_API void MR_BooleanResultMapper_DestroyArray(const MR_BooleanResultMapper *_this)
Destroys a heap-allocated array of MR_BooleanResultMapper. Does nothing if the pointer is null.
MRC_API const MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_OffsetPtr(const MR_BooleanResultMapper_Maps *ptr, ptrdiff_t i)
Offsets a pointer to an array element by i positions (not bytes). Use only if you're certain that the...
@ MR_BooleanResultMapper_MapObject_A
Definition MRBooleanOperation.h:77
@ MR_BooleanResultMapper_MapObject_Count
Definition MRBooleanOperation.h:79
@ MR_BooleanResultMapper_MapObject_B
Definition MRBooleanOperation.h:78
MRC_API const MR_WholeEdgeMap * MR_BooleanResultMapper_Maps_Get_old2newEdges(const MR_BooleanResultMapper_Maps *_this)
MRC_API const MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_getMaps(const MR_BooleanResultMapper *_this, MR_BooleanResultMapper_MapObject index)
MRC_API MR_BooleanResultMapper * MR_BooleanResultMapper_ConstructFromAnother(MR_PassBy _other_pass_by, MR_BooleanResultMapper *_other)
MRC_API MR_BooleanInternalParameters * MR_BooleanInternalParameters_OffsetMutablePtr(MR_BooleanInternalParameters *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 MR_FaceBitSet * MR_BooleanResultMapper_newFaces(const MR_BooleanResultMapper *_this)
MRC_API MR_BooleanResultMapper_Maps * MR_BooleanResultMapper_Maps_ConstructFrom(MR_PassBy cut2origin_pass_by, MR_FaceMap *cut2origin, MR_PassBy cut2newFaces_pass_by, MR_FaceMap *cut2newFaces, MR_PassBy old2newEdges_pass_by, MR_WholeEdgeMap *old2newEdges, MR_PassBy old2newVerts_pass_by, MR_VertMap *old2newVerts, bool identity)
MRC_API void MR_BooleanResultMapper_Maps_Set_old2newEdges(MR_BooleanResultMapper_Maps *_this, MR_PassBy value_pass_by, MR_WholeEdgeMap *value)
MRC_API void MR_BooleanResultMapper_Maps_Set_identity(MR_BooleanResultMapper_Maps *_this, bool value)
struct MR_expected_MR_Mesh_std_string MR_expected_MR_Mesh_std_string
Definition MRCtm.h:18
struct MR_Mesh MR_Mesh
Definition MRCtm.h:13
MR_PassBy
Definition common.h:19
#define MRC_API
Definition exports.h:11
Definition MRAffineXf.h:36